summaryrefslogtreecommitdiff
path: root/lib/libc/stdio
diff options
context:
space:
mode:
authorDavid Schultz <das@FreeBSD.org>2010-01-24 20:15:59 +0000
committerDavid Schultz <das@FreeBSD.org>2010-01-24 20:15:59 +0000
commit903d5593ab0ce02ab5a829ed98fae5c704b37c29 (patch)
treeb315bd7e608ef1bccba8423652d2cdeffaad9aeb /lib/libc/stdio
parenteb63bf5c833bb930c7998a47bd5c8363e02c122f (diff)
Notes
Diffstat (limited to 'lib/libc/stdio')
-rw-r--r--lib/libc/stdio/getdelim.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/stdio/getdelim.c b/lib/libc/stdio/getdelim.c
index 7af154f6af51..d7d5627ec92f 100644
--- a/lib/libc/stdio/getdelim.c
+++ b/lib/libc/stdio/getdelim.c
@@ -120,8 +120,8 @@ getdelim(char ** __restrict linep, size_t * __restrict linecapp, int delim,
goto error;
}
- if (*linecapp == 0)
- *linep = NULL;
+ if (*linep == NULL)
+ *linecapp = 0;
if (fp->_r <= 0 && __srefill(fp)) {
/* If fp is at EOF already, we just need space for the NUL. */