X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=blobdiff_plain;f=src%2Fdaemon%2Fsysdbd.c;h=6952c1ce7df5a85ab5a12804acef8f3900221b4a;hp=4fbf48f449b1eca24b4dc4bcdd7db346fe807da8;hb=ddb933096618a6bceded29e4dc2b37cb72134366;hpb=095018687aa443dad20e9a0a5fbb7dd3d6315391 diff --git a/src/daemon/sysdbd.c b/src/daemon/sysdbd.c index 4fbf48f..6952c1c 100644 --- a/src/daemon/sysdbd.c +++ b/src/daemon/sysdbd.c @@ -32,7 +32,7 @@ #include "sysdb.h" #include "core/plugin.h" #include "core/store.h" -#include "core/error.h" +#include "utils/error.h" #include "frontend/sock.h" @@ -171,6 +171,7 @@ static void * backend_handler(void __attribute__((unused)) *data) { sdb_plugin_collector_loop(&plugin_main_loop); + sdb_log(SDB_LOG_INFO, "Shutting down backend thread"); return NULL; } /* backend_handler */ @@ -281,6 +282,7 @@ main(int argc, char **argv) sdb_log(SDB_LOG_INFO, "Waiting for backend thread to terminate"); plugin_main_loop.do_loop = 0; + pthread_kill(backend_thread, SIGINT); pthread_join(backend_thread, NULL); sdb_fe_sock_destroy(sock); }