]> code.delx.au - gnu-emacs/commitdiff
(getline): Don't miss CRLF pairs when the CR and LF are
authorRichard M. Stallman <rms@gnu.org>
Tue, 6 May 1997 19:30:49 +0000 (19:30 +0000)
committerRichard M. Stallman <rms@gnu.org>
Tue, 6 May 1997 19:30:49 +0000 (19:30 +0000)
read in separate blocks.

lib-src/pop.c

index 9292998e2882fa938674cda290ac987a188eb3f6..48e9df7b5d505f013c8ecd61716112bf420daca9 100644 (file)
@@ -1316,7 +1316,9 @@ getline (server)
                fprintf (stderr, "<<< %s\n", server->buffer);
              return (server->buffer);
            }
-         search_offset += ret;
+         /* As above, the "- 1" here is to account for the fact that
+            we may have read a CR without its accompanying LF. */
+         search_offset += ret - 1;
        }
     }