I guess that flushing could help:
fflush(stdout);
But in my test I achieved success by adding a \n to the string. That sscanf won't start with "unfinished" strings I guess.
\n
sscanf