client: Exit with non-zero status when unix socket is closed
authorAmitay Isaacs <amitay@gmail.com>
Mon, 24 Jun 2013 07:37:15 +0000 (17:37 +1000)
committerAmitay Isaacs <amitay@gmail.com>
Wed, 14 Aug 2013 01:08:29 +0000 (11:08 +1000)
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
(cherry picked from commit 733fc909425860f6a02c205c2d8f34a731853922)

client/ctdb_client.c

index 0f0f17566eebe9589dcac58a9eb4d46433ecf083..7782369bcaa7d913a6e60a743862e0db7fd84400 100644 (file)
@@ -201,8 +201,8 @@ static void ctdb_client_read_cb(uint8_t *data, size_t cnt, void *args)
        talloc_steal(tmp_ctx, hdr);
 
        if (cnt == 0) {
-               DEBUG(DEBUG_INFO,("Daemon has exited - shutting down client\n"));
-               exit(0);
+               DEBUG(DEBUG_CRIT,("Daemon has exited - shutting down client\n"));
+               exit(1);
        }
 
        if (cnt < sizeof(*hdr)) {