diff options
| author | Andrey A. Chernov <ache@FreeBSD.org> | 1997-02-05 20:54:16 +0000 |
|---|---|---|
| committer | Andrey A. Chernov <ache@FreeBSD.org> | 1997-02-05 20:54:16 +0000 |
| commit | 628abd1b29bdc80df0330fef22c142bfba73c98e (patch) | |
| tree | df4687a46c93516075277c812ef6ae3e29fc4932 /lib/libc | |
| parent | 76dafb8954ea032dfedfe51a5bb873fc2012758d (diff) | |
Notes
Diffstat (limited to 'lib/libc')
| -rw-r--r-- | lib/libc/stdio/vfscanf.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/libc/stdio/vfscanf.c b/lib/libc/stdio/vfscanf.c index f26db86d2575..f2699b8d3676 100644 --- a/lib/libc/stdio/vfscanf.c +++ b/lib/libc/stdio/vfscanf.c @@ -677,7 +677,10 @@ __sccl(tab, fmt) c = *fmt++; /* get new first char */ } else v = 0; /* default => reject */ + + /* XXX: Will not work if sizeof(tab*) > sizeof(char) */ (void) memset(tab, v, 256); + if (c == 0) return (fmt - 1);/* format ended before closing ] */ |
