In defense of scanf() (Re: Re^2: scanf(..))

Norman Diamond diamond at diamond.csl.sony.junet
Tue Jun 20 16:00:56 AEST 1989


In article <1134 at vsi.COM> friedl at vsi.COM (Stephen J. Friedl) writes:

>since strtok places NULs in the string, the
>environment was getting corrupted for the child.

>Neither of these are bugs -- they are documented parts of the
>function -- but nevertheless we have been hit with these gotchas.

You mean that these are design bugs instead of coding bugs.
They are documented bugs instead of undocumented bugs.
Just like gets() has some documented design bugs.

Funny, existing practices that consisted of documented bugs really
have been standardized.  Only existing practices that consisted of
quasi-documented but necessary features have been omitted from the
standardization.

--
Norman Diamond, Sony Computer Science Lab (diamond%csl.sony.jp at relay.cs.net)
 The above opinions are claimed by your machine's init process (pid 1), after
 being disowned and orphaned.  However, if you see this at Waterloo, Stanford,
 or Anterior, then their administrators must have approved of these opinions.



More information about the Comp.lang.c mailing list