Skip to content

Commit f7efb1e

Browse files
author
crass
committed
Make all PDEBUG calls print the PID, helpful for multiprocess applications.
1 parent 369f926 commit f7efb1e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/debug.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#ifdef DEBUG
55
# include <stdio.h>
66
# define PSTDERR(fmt, args...) do { dprintf(2,fmt, ## args); } while(0)
7-
# define PDEBUG(fmt, args...) PSTDERR("DEBUG:"fmt, ## args)
7+
# define PDEBUG(fmt, args...) PSTDERR("DEBUG:pid[%d]:"fmt, getpid(), ## args)
88
# define DEBUGDECL(args...) args
99

1010
# include "core.h"

0 commit comments

Comments
 (0)