summaryrefslogtreecommitdiff
path: root/lib-src
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1996-07-23 16:32:24 +0000
committerRichard M. Stallman <rms@gnu.org>1996-07-23 16:32:24 +0000
commitb3c860e522af3cc24f8b1c187bb988faac6b7824 (patch)
tree102a4f5b15adc0143e196543c17512234964bbd2 /lib-src
parentd45847608e4f53b7cd5041aba236dd1c9c4feb89 (diff)
downloademacs-b3c860e522af3cc24f8b1c187bb988faac6b7824.tar.gz
(readline_internal) [DOS_NT]: Don't include CRs when
computing character positions in source files.
Diffstat (limited to 'lib-src')
-rw-r--r--lib-src/etags.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib-src/etags.c b/lib-src/etags.c
index 97f860a96a4..35e396c3be7 100644
--- a/lib-src/etags.c
+++ b/lib-src/etags.c
@@ -4105,7 +4105,16 @@ readline_internal (linebuffer, stream)
if (p > buffer && p[-1] == '\r')
{
*--p = '\0';
+#ifdef DOS_NT
+ /* Assume CRLF->LF translation will be performed by Emacs
+ when loading this file, so CRs won't appear in the buffer.
+ It would be cleaner to compensate within Emacs;
+ however, Emacs does not know how many CRs were deleted
+ before any given point in the file. */
+ chars_deleted = 1;
+#else
chars_deleted = 2;
+#endif
}
else
{