diff --git a/hv_kvp_daemon.c b/hv_kvp_daemon.c index fd530c6..3d62d09 100644 --- a/hv_kvp_daemon.c +++ b/hv_kvp_daemon.c @@ -331,7 +331,10 @@ int main(void) char *key_value; char *key_name; - daemon(1, 0); + if (daemon(1, 0) < 0) { + perror("daemon"); + return 1; + } openlog("KVP", 0, LOG_USER); syslog(LOG_INFO, "KVP starting; pid is:%d", getpid()); /* diff --git a/hyper-v.changes b/hyper-v.changes index 619dec8..00784b2 100644 --- a/hyper-v.changes +++ b/hyper-v.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Fri Jun 17 10:58:42 CEST 2011 - ohering@suse.de + +- catch errors from daemon() + ------------------------------------------------------------------- Fri Jun 17 10:33:50 CEST 2011 - ohering@suse.de