LIBCTDB uninitialized inqueue element
authorRonnie Sahlberg <ronniesahlberg@gmail.com>
Mon, 10 Jan 2011 20:37:17 +0000 (07:37 +1100)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Mon, 10 Jan 2011 20:37:17 +0000 (07:37 +1100)
From Michael Anderson,
initialize the inqueue element of the ctdb structure to NULL,
else it might be used uninitialized and cause a segv.

libctdb/ctdb.c

index 264952485797a065fb3d689ef20dc6ed2face204..e06c66ca85497d3b1904ea89d77a31745721b1bd 100644 (file)
@@ -154,6 +154,7 @@ struct ctdb_connection *ctdb_connect(const char *addr,
        ctdb->outq = NULL;
        ctdb->doneq = NULL;
        ctdb->in = NULL;
+       ctdb->inqueue = NULL;
        ctdb->message_handlers = NULL;
        ctdb->next_id = 0;
        ctdb->broken = false;