From 627c573af25b602ac64c36b01c8163c592cbb494 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Mon, 26 Apr 2004 17:45:47 +0000 Subject: Debugging Fixes --- daemon/misc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'daemon/misc.c') diff --git a/daemon/misc.c b/daemon/misc.c index 9dba389..15344ce 100644 --- a/daemon/misc.c +++ b/daemon/misc.c @@ -170,15 +170,15 @@ void ha_unlock(pthread_mutex_t* mtx) int ha_confbool(const char* name, const char* conf, int* value) { - ASSERT(name && conf && value); + ASSERT(name && value); - if(value == NULL || - value[0] == 0 || + if(conf == NULL || + conf[0] == 0 || strcasecmp(conf, "0") == 0 || strcasecmp(conf, "no") == 0 || strcasecmp(conf, "false") == 0 || strcasecmp(conf, "f") == 0 || - strcasecmp(conf, "off")) + strcasecmp(conf, "off") == 0) { *value = 0; return HA_OK; @@ -188,7 +188,7 @@ int ha_confbool(const char* name, const char* conf, int* value) strcasecmp(conf, "yes") == 0 || strcasecmp(conf, "true") == 0 || strcasecmp(conf, "t") == 0 || - strcasecmp(conf, "on")) + strcasecmp(conf, "on") == 0) { *value = 1; return HA_OK; -- cgit v1.2.3