From: David Lawrence Ramsey Date: Tue, 17 Aug 2004 19:28:54 +0000 (+0000) Subject: and add last missing bit X-Git-Tag: v1.3.4~2 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=35fb55aba24afa658bdc7d74d0de0fe6b3282c95;p=nano.git and add last missing bit git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1904 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- diff --git a/src/utils.c b/src/utils.c index 4c52d1d3..738d576f 100644 --- a/src/utils.c +++ b/src/utils.c @@ -290,6 +290,7 @@ ssize_t ngetdelim(char **lineptr, size_t *n, int delim, FILE *stream) /* Null terminate the buffer. */ null_at(lineptr, indx++); + *n = indx; /* The last line may not have the delimiter, we have to return what * we got and the error will be seen on the next iteration. */