[Feature][T106]ZXW P56U09 code
Only Configure: Yes
Affected branch: master
Affected module: unknow
Is it affected on both ZXIC and MTK: only ZXIC
Self-test: No
Doc Update: No
Change-Id: I3cbd8b420271eb20c2b40ebe5c78f83059cd42f3
diff --git a/ap/libc/glibc/glibc-2.23/stdio-common/bug9.c b/ap/libc/glibc/glibc-2.23/stdio-common/bug9.c
new file mode 100644
index 0000000..732904d
--- /dev/null
+++ b/ap/libc/glibc/glibc-2.23/stdio-common/bug9.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+#include <string.h>
+
+int
+main(int argc, char *argv[])
+{
+ char buf[100];
+ int a, b;
+ int status = 0;
+
+ sscanf ("12ab", "%dab%n", &a, &b);
+ sprintf (buf, "%d, %d", a, b);
+ puts (buf);
+ status |= strcmp (buf, "12, 4");
+
+ sscanf ("12ab100", "%dab%n100", &a, &b);
+ sprintf (buf, "%d, %d", a, b);
+ puts (buf);
+ status |= strcmp (buf, "12, 4");
+
+ return status;
+}