[comp.lang.c] Scaring scanf

leo@philmds.UUCP (Leo de Wit) (06/18/88)

This is a SERIOUS newsgroup, but still ...

In article <4390@haddock.ISC.COM> karl@haddock.ima.isc.com (Karl Heuer) writes:
<In article <1793@akgua.ATT.COM> brb@akgua.ATT.COM (Brian R. Bainter) writes:
<< [lots of stuff about 'annoying, buggy scanf()']...
< [Karl explains the correct use of scanf() and that it is perfectly safe...]
<If you want to ignore all input up to and including the newline, you can add
<"%*[^\n]%*c" to the end of the scanf format.
<
<Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint

That will do to scare him (scanf) off, I think ... 8-)

	Leo.