From 798c015d114223b53caf5affb5820dbecb69dc4d Mon Sep 17 00:00:00 2001 From: Jeff Johnston Date: Fri, 11 Jan 2002 22:06:09 +0000 Subject: 2002-01-11 Jeff Johnston * libc/stdio/vfscanf.c (__svfscanf_r): Change loop that reads blanks from the input file to break if EOF reached rather than end processing. --- newlib/libc/stdio/vfscanf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'newlib/libc/stdio') diff --git a/newlib/libc/stdio/vfscanf.c b/newlib/libc/stdio/vfscanf.c index 8f49141f1..f6c3c930b 100644 --- a/newlib/libc/stdio/vfscanf.c +++ b/newlib/libc/stdio/vfscanf.c @@ -292,9 +292,7 @@ __svfscanf_r (rptr, fp, fmt0, ap) { for (;;) { - if (BufferEmpty) - return nassigned; - if (!isspace (*fp->_p)) + if (BufferEmpty || !isspace (*fp->_p)) break; nread++, fp->_r--, fp->_p++; } -- cgit v1.2.3