diff options
author | Milan Broz <mbroz@redhat.com> | 2011-01-17 23:14:05 +0000 |
---|---|---|
committer | Milan Broz <mbroz@redhat.com> | 2011-01-17 23:14:05 +0000 |
commit | 4c29343443cb0ad14ac86331b4ed58b7266f7d46 (patch) | |
tree | 9b471cbd848d573aeea293151f457a20e3120f0e /daemons/dmeventd/dmeventd.c | |
parent | 92e6277c28bedb2df5bb6ac2efca8f8b07ab0b18 (diff) | |
download | lvm2-4c29343443cb0ad14ac86331b4ed58b7266f7d46.tar.gz lvm2-4c29343443cb0ad14ac86331b4ed58b7266f7d46.tar.xz lvm2-4c29343443cb0ad14ac86331b4ed58b7266f7d46.zip |
Remove DEBUGLOG from dmeventd.
Diffstat (limited to 'daemons/dmeventd/dmeventd.c')
-rw-r--r-- | daemons/dmeventd/dmeventd.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/daemons/dmeventd/dmeventd.c b/daemons/dmeventd/dmeventd.c index 2b454f90..4ac5e25f 100644 --- a/daemons/dmeventd/dmeventd.c +++ b/daemons/dmeventd/dmeventd.c @@ -95,8 +95,6 @@ static pthread_mutex_t _global_mutex; #define THREAD_STACK_SIZE (300*1024) -#define DEBUGLOG(fmt, args...) _debuglog(fmt, ## args) - int dmeventd_debug = 0; static int _foreground = 0; static int _restart = 0; @@ -203,24 +201,6 @@ static DM_LIST_INIT(_timeout_registry); static pthread_mutex_t _timeout_mutex = PTHREAD_MUTEX_INITIALIZER; static pthread_cond_t _timeout_cond = PTHREAD_COND_INITIALIZER; -static void _debuglog(const char *fmt, ...) -{ - time_t P; - va_list ap; - - if (!_foreground) - return; - - va_start(ap,fmt); - - time(&P); - fprintf(stderr, "dmeventd[%p]: %.15s ", (void *) pthread_self(), ctime(&P)+4 ); - vfprintf(stderr, fmt, ap); - fprintf(stderr, "\n"); - - va_end(ap); -} - /* Allocate/free the status structure for a monitoring thread. */ static struct thread_status *_alloc_thread_status(struct message_data *data, struct dso_data *dso_data) @@ -1621,7 +1601,7 @@ static int _set_oom_adj(int val) if (stat(OOM_ADJ_FILE, &st) == -1) { if (errno == ENOENT) - DEBUGLOG(OOM_ADJ_FILE " not found"); + perror(OOM_ADJ_FILE " not found"); else perror(OOM_ADJ_FILE ": stat failed"); return 1; |