logger(1) hiccups on % signs
Roy Smith
roy at phri.UUCP
Wed Aug 3 23:55:36 AEST 1988
In article <4653 at fluke.COM> news at tc.fluke.COM (UNIX Network News) writes:
> Change
> syslog(pri, buf);
> to
> syslog(pri, "%s", buf);
This should go on the list of "common insidious bugs" and a warning
be included in the man page for every printf and printf-like routine. Didn't
I see essentially the same fix for bnews a while ago? As I remember, it made
entries in a log file by doing
printf (article_id)
instead of
printf ("%s", article_id);
and went off the deep end when article ids with %'s in them started showing
up (probably from an andrew system).
--
Roy Smith, System Administrator
Public Health Research Institute
{allegra,philabs,cmcl2,rutgers}!phri!roy -or- phri!roy at uunet.uu.net
"The connector is the network"
More information about the Comp.bugs.4bsd.ucb-fixes
mailing list