1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-12-24 17:51:17 +03:00
2000-10-04  Jakub Jelinek  <jakub@redhat.com>

	* stdio-common/vfscanf.c (_IO_vfscanf): For [ conversion do
	input_error() if EOF is seen before processing.
	* stdio-common/tstscanf.c (main): Add testcase.
This commit is contained in:
Ulrich Drepper
2000-10-04 22:50:20 +00:00
parent 883ba31595
commit d64e603ae7
3 changed files with 30 additions and 18 deletions

View File

@@ -46,6 +46,12 @@ main (int argc, char **argv)
result = 1;
}
if (sscanf ("", "%10[a-z]", buf) != EOF)
{
fputs ("test failed!\n", stdout);
result = 1;
}
sscanf ("conversion] Zero flag Ze]ro#\n", "%*[^]] %[^#]\n", buf);
if (strcmp (buf, "] Zero flag Ze]ro") != 0)
{