summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
authordas <das@FreeBSD.org>2012-04-22 21:28:33 +0000
committerdas <das@FreeBSD.org>2012-04-22 21:28:33 +0000
commit1c56974f7a0b1bec1ffa7ae8f35f90036d98001e (patch)
treebb6a90885c9a96f0175b45877546297f448b8819 /lib/libc
parent114cb5b35711a06874931458aaef95050d4f3e5d (diff)
downloadFreeBSD-src-1c56974f7a0b1bec1ffa7ae8f35f90036d98001e.zip
FreeBSD-src-1c56974f7a0b1bec1ffa7ae8f35f90036d98001e.tar.gz
Bugfix: Include whitespace characters in the count of the number of
characters read.
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/stdio/vfwscanf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/stdio/vfwscanf.c b/lib/libc/stdio/vfwscanf.c
index f715672..6b4d8c5 100644
--- a/lib/libc/stdio/vfwscanf.c
+++ b/lib/libc/stdio/vfwscanf.c
@@ -506,7 +506,7 @@ __vfwscanf(FILE * __restrict fp, locale_t locale,
if (iswspace(c)) {
while ((c = __fgetwc(fp, locale)) != WEOF &&
iswspace_l(c, locale))
- ;
+ nread++;
if (c != WEOF)
__ungetwc(c, fp, locale);
continue;
OpenPOWER on IntegriCloud