diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2002-02-02 13:44:24 +0100 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2002-02-02 13:44:24 +0100 |
commit | ddec0a101bfb97caa23ca731b8041547717a5eb3 (patch) | |
tree | 10ae250d9740fae442ca54466ca69e175f223ee9 /tools.h | |
parent | 2a31a4eca81b75bfab9a9fbbe2aa8f9eeec38f9f (diff) | |
download | vdr-ddec0a101bfb97caa23ca731b8041547717a5eb3.tar.gz vdr-ddec0a101bfb97caa23ca731b8041547717a5eb3.tar.bz2 |
Changed the [dei]syslog macros to use var args; fixed error handling in establishing an SVDRP connection
Diffstat (limited to 'tools.h')
-rw-r--r-- | tools.h | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: tools.h 1.39 2002/01/26 15:38:10 kls Exp $ + * $Id: tools.h 1.40 2002/02/02 13:16:47 kls Exp $ */ #ifndef __TOOLS_H @@ -20,9 +20,9 @@ extern int SysLogLevel; -#define esyslog if (SysLogLevel > 0) syslog -#define isyslog if (SysLogLevel > 1) syslog -#define dsyslog if (SysLogLevel > 2) syslog +#define esyslog(a...) void( (SysLogLevel > 0) ? syslog(a) : void() ) +#define isyslog(a...) void( (SysLogLevel > 1) ? syslog(a) : void() ) +#define dsyslog(a...) void( (SysLogLevel > 2) ? syslog(a) : void() ) #define LOG_ERROR esyslog(LOG_ERR, "ERROR (%s,%d): %m", __FILE__, __LINE__) #define LOG_ERROR_STR(s) esyslog(LOG_ERR, "ERROR: %s: %m", s) |