projects
/
musl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
fix failure to distinguish input/match failure in wide %[ scanf
[musl]
/
src
/
stdio
/
vfwscanf.c
diff --git
a/src/stdio/vfwscanf.c
b/src/stdio/vfwscanf.c
index
a52ba3a
..
dbba865
100644
(file)
--- a/
src/stdio/vfwscanf.c
+++ b/
src/stdio/vfwscanf.c
@@
-264,7
+264,9
@@
int vfwscanf(FILE *f, const wchar_t *fmt, va_list ap)
}
if (width) ungetwc(c, f);
- if (!gotmatch) goto match_fail;
+ if (!gotmatch)
+ if (c>=0) goto match_fail;
+ else goto input_fail;
if (*p==']') p++;
while (*p!=']') {