🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.bugs.4bsd
Article #1116

logger(1) hiccups on % signs

#1116
From: UNIX Network News
Date: Wed, 03 Aug 1988 01:43
33 lines
1262 bytes
From: jeff@tc.fluke.COM (Jeff Stearns)
Path: fluke!jeff

Site:   John Fluke Mfg. Co., Inc.

Subject: logger(1) hiccups on % signs
 
Index:  ucb/logger UNIX 4.3BSD

Description:
        Logger(1) mishandles messages containing % signs, treating them as
        though they were printf(3) conversion specifiers.  As a result,
        randomly-formatted strings are logged.
         
        Sometimes you can provoke a core dump. 
 
Repeat-By:
        logger -t testing -p user.info 
        here comes a % sign 
        here come two %% signs
        100%flood insurance 18%dairy cows 5%light bulbs
        ^D
Fix:
        Change 
            syslog(pri, buf);
        to  
            syslog(pri, "%s", buf);
-- 
		 Jeff Stearns
	 Domain: jeff@tc.fluke.COM
	  Voice: +1 206 356 5064
    If you must: {uw-beaver,microsoft,sun}!fluke!jeff
	   USPS: John Fluke Mfg. Co. / P.O. Box C9090 / Everett WA  98206
Technical Details
Message-ID: <4653@fluke.COM>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!lll-tis!ames!mailrus!cornell!uw-beaver!fluke!news

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!lll-tis!ames!mailrus!cornell!uw-beaver!fluke!news
From: news@tc.fluke.COM (UNIX Network News)
Newsgroups: comp.bugs.4bsd
Subject: logger(1) hiccups on % signs
Message-ID: <4653@fluke.COM>
Date: 3 Aug 88 01:43:05 GMT
Organization: John Fluke Mfg. Co., Inc., Everett, WA
Lines: 32