From: Sebastian Harl Date: Mon, 9 Jun 2014 12:41:12 +0000 (+0200) Subject: Merged branch 'master' of git://git.tokkee.org/sysdb. X-Git-Tag: sysdb-0.2.0~61 X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=commitdiff_plain;h=4cf5f6607b603fd50fc667fdea5cda800daf5a78;hp=bd226461afd5fb14daec426877db14bcb113d5c4 Merged branch 'master' of git://git.tokkee.org/sysdb. --- diff --git a/autogen.sh b/autogen.sh index e4ffee0..87fd59f 100755 --- a/autogen.sh +++ b/autogen.sh @@ -1,7 +1,11 @@ #! /bin/sh -libtoolize=libtoolize +if ! which yacc > /dev/null 2>&1 || ! which lex > /dev/null 2>&1; then + echo "yacc and lex are required to build SysDB" >&2 + exit 1 +fi +libtoolize=libtoolize if which glibtoolize > /dev/null 2>&1; then libtoolize=glibtoolize fi diff --git a/src/tools/sysdbd/main.c b/src/tools/sysdbd/main.c index b8e97a3..96fe6a6 100644 --- a/src/tools/sysdbd/main.c +++ b/src/tools/sysdbd/main.c @@ -236,7 +236,7 @@ main_loop(void) int status = 0; - while (42) { + while (status == 0) { size_t i; plugin_main_loop.do_loop = 1; @@ -261,10 +261,8 @@ main_loop(void) } /* break on error */ - if (i < listen_addresses_num) { - status = 1; + if (status) break; - } sdb_log(SDB_LOG_INFO, "SysDB daemon "SDB_VERSION_STRING SDB_VERSION_EXTRA " (libsysdb %s%s, pid %i) initialized " @@ -294,6 +292,8 @@ main_loop(void) } /* clean up in case we exited the loop on error */ + plugin_main_loop.do_loop = 0; + frontend_main_loop.do_loop = 0; pthread_kill(backend_thread, SIGINT); pthread_join(backend_thread, NULL);