[uClibc-cvs] cvs commit to uClibc/libc/stdio by davidm

cvs at uclinux.org cvs at uclinux.org
Thu Aug 9 13:44:22 UTC 2001


Repository: uClibc/libc/stdio
who:        davidm
time:       Thu Aug  9 09:44:22 EDT 2001


Log Message:


Add in changes from philipc at lineo:

Fix three bugs and bring into line with glibc:

1. The first character read using getc() was being ignored if it was EOF.
Normally this is okay because the next getc() returns EOF as well, but
for sscanf, this was causing us to skip the null terminator and start
scanning whatever happened to be next in memory.

2. %s, %c, and %[ formats now return -1 if EOF is reached before any
characters are read, instead of 0.  This was causing an infinite loop
in diald.

3. Default to base 10 for %i fields if not prefix modifier present.



Files:

changed:    scanf.c






More information about the uClibc-cvs mailing list