From 243d0c2d4a9b09326e5d94a24d31419db71a13d5 Mon Sep 17 00:00:00 2001 From: das Date: Sun, 22 Apr 2012 21:22:14 +0000 Subject: Bugfix: %n doesn't count as a conversion, so sscanf("abc", "ab%ncd", &i) returns EOF, not 0. --- lib/libc/stdio/vfscanf.c | 1 - lib/libc/stdio/vfwscanf.c | 1 - 2 files changed, 2 deletions(-) (limited to 'lib/libc/stdio') diff --git a/lib/libc/stdio/vfscanf.c b/lib/libc/stdio/vfscanf.c index 9b8b1b2..f9b7e55 100644 --- a/lib/libc/stdio/vfscanf.c +++ b/lib/libc/stdio/vfscanf.c @@ -703,7 +703,6 @@ literal: break; case 'n': - nconversions++; if (flags & SUPPRESS) /* ??? */ continue; if (flags & SHORTSHORT) diff --git a/lib/libc/stdio/vfwscanf.c b/lib/libc/stdio/vfwscanf.c index 79368e7..f715672 100644 --- a/lib/libc/stdio/vfwscanf.c +++ b/lib/libc/stdio/vfwscanf.c @@ -650,7 +650,6 @@ literal: break; case 'n': - nconversions++; if (flags & SUPPRESS) /* ??? */ continue; if (flags & SHORTSHORT) -- cgit v1.1