NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/50414: postfix extensively uses printf("%m")



On Nov 9,  1:10am, dholland%netbsd.org@localhost (dholland%netbsd.org@localhost) wrote:
-- Subject: bin/50414: postfix extensively uses printf("%m")

| >Number:         50414
| >Category:       bin
| >Synopsis:       postfix extensively uses printf("%m")
| >Confidential:   no
| >Severity:       serious
| >Priority:       high
| >Responsible:    bin-bug-people
| >State:          open
| >Class:          sw-bug
| >Submitter-Id:   net
| >Arrival-Date:   Mon Nov 09 01:10:00 +0000 2015
| >Originator:     David A. Holland
| >Release:        NetBSD 7.99.21 (20151108)
| >Organization:
| >Environment:
| System: NetBSD valkyrie 7.99.1 NetBSD 7.99.1 (VALKYRIE) #17: Wed Oct 14 03:21:03 EDT 2015  dholland@valkyrie:/usr/src/sys/arch/amd64/compile/VALKYRIE amd64
| Architecture: x86_64
| Machine: amd64
| >Description:
| 
| 	%m as a format string is defined only for syslog(3); however,
| 	postfix's logging functions send only text to syslog(3), not
| 	formats; the formats are all handled with vsnprintf/vfprintf/
| 	whatnot.
| 
| 	Ergo, any %m passed to postfix's logging functions is not
| 	interpreted. Unfortunately, there are a lot of these.
| 
| >How-To-Repeat:
| 
| 	find external/ibm-public -name '*.[ch]' | grep '"[^"]*%[^efgcpuoxds"]*m'
| 
|    	This produces 961 hits currently, most of which seem to be in
|    	need of fixing.

Nothing needs to be fixed. Postfix has its own string, buffer, and printing
systems:

http://nxr.netbsd.org/xref/src/external/ibm-public/postfix/dist/src/util/vbuf_print.c#247

christos


Home | Main Index | Thread Index | Old Index