From d00bd1724bd9f75f5a7b8e0368428c2f0d6d3c26 Mon Sep 17 00:00:00 2001 From: "kay.sievers@vrfy.org" Date: Thu, 4 Mar 2004 00:57:29 -0800 Subject: [PATCH] overall trivial trivial cleanup Here I try to make the style a bit more consistant in the different files, so that new patches just copy the 'right' one :) Some "magic" numbers are replaced and udevtest.c is catched up with udev. --- logging.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'logging.h') diff --git a/logging.h b/logging.h index 1c27917f61..40c342c3ab 100644 --- a/logging.h +++ b/logging.h @@ -34,6 +34,8 @@ #include #include +#define LOGNAME_SIZE 42 + #undef info #define info(format, arg...) \ do { \ @@ -61,12 +63,12 @@ extern void log_message(int level, const char *format, ...) __attribute__ ((format (printf, 2, 3))); /* each program that uses syslog must declare this variable somewhere */ -extern unsigned char logname[42]; +extern unsigned char logname[LOGNAME_SIZE]; #undef init_logging static inline void init_logging(char *program_name) { - snprintf(logname, 42,"%s[%d]", program_name, getpid()); + snprintf(logname, LOGNAME_SIZE,"%s[%d]", program_name, getpid()); openlog(logname, 0, LOG_DAEMON); } -- cgit v1.2.3-54-g00ecf