diff options
author | Kalle Wallin <kaw@linux.se> | 2004-07-03 13:21:26 +0000 |
---|---|---|
committer | Kalle Wallin <kaw@linux.se> | 2004-07-03 13:21:26 +0000 |
commit | 1c515ff7791fd186dc82e80134ac47273c43d442 (patch) | |
tree | efadd50101726db1c78446a53684a57b1cd03a1e /src/main.c | |
parent | bb2b7a65ed6ce964527e07843ec0ed86f0b45220 (diff) | |
download | mpd-1c515ff7791fd186dc82e80134ac47273c43d442.tar.gz mpd-1c515ff7791fd186dc82e80134ac47273c43d442.tar.xz mpd-1c515ff7791fd186dc82e80134ac47273c43d442.zip |
Replaced the debug macro with a function
git-svn-id: https://svn.musicpd.org/ncmpc/trunk@1780 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c index 2ace29740..abe60bf15 100644 --- a/src/main.c +++ b/src/main.c @@ -133,6 +133,24 @@ catch_sigint( int sig ) exit(EXIT_SUCCESS); } +#ifdef DEBUG +void +D(char *format, ...) +{ + if( options.debug ) + { + gchar *msg; + va_list ap; + + va_start(ap,format); + msg = g_strdup_vprintf(format,ap); + va_end(ap); + fprintf(stderr, "%s", msg); + g_free(msg); + } +} +#endif + int main(int argc, const char *argv[]) { |