Fix vscanf_callback(3) not ungetcing the last character when stopping.

This commit is contained in:
Jonas 'Sortie' Termansen 2014-03-08 22:21:45 +01:00
parent 1986bc2ba2
commit 02c18f868f
1 changed files with 3 additions and 0 deletions

View File

@ -108,7 +108,10 @@ int vscanf_callback(void* fp,
{
case MODE_INIT:
if ( !*format )
{
ungetc(ic, fp);
goto break_loop;
}
if ( isspace(*formatuc) )
{
if ( isspace(ic) )