git.samba.org
/
sahlberg
/
ctdb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
680b4fb
)
add an atexit() that will print "CTDB daemon shutting down" in the log
author
Ronnie Sahlberg
<sahlberg@ronnie>
Mon, 20 Aug 2007 23:43:53 +0000
(09:43 +1000)
committer
Ronnie Sahlberg
<sahlberg@ronnie>
Mon, 20 Aug 2007 23:43:53 +0000
(09:43 +1000)
when the main daemon exits
server/ctdb_daemon.c
patch
|
blob
|
history
diff --git
a/server/ctdb_daemon.c
b/server/ctdb_daemon.c
index 78c67b3ccc781b598331fdf436e4663f6a769ce2..f216ca4365d74f092d602887d4cc73b50b7bc9a4 100644
(file)
--- a/
server/ctdb_daemon.c
+++ b/
server/ctdb_daemon.c
@@
-616,6
+616,10
@@
static int unlink_destructor(const char *name)
return 0;
}
+static void print_exit_message(void)
+{
+ DEBUG(0,("CTDB daemon shutting down\n"));
+}
/*
start the protocol going as a daemon
@@
-640,6
+644,9
@@
int ctdb_start_daemon(struct ctdb_context *ctdb, bool do_fork)
return 0;
}
+ /* Make sure we log something when the daemon terminates */
+ atexit(print_exit_message);
+
tdb_reopen_all(False);
if (do_fork) {