From 630f169653b731025aeb0babcd8cf0710bc5d316 Mon Sep 17 00:00:00 2001 From: Martin Schwenke Date: Wed, 1 Jun 2016 15:56:42 +1000 Subject: [PATCH] ctdb-recoverd: Fix buggy function return on memory allocation failure Signed-off-by: Martin Schwenke Reviewed-by: Amitay Isaacs --- ctdb/server/ctdb_recoverd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ctdb/server/ctdb_recoverd.c b/ctdb/server/ctdb_recoverd.c index adff56cdce5..538d4301adb 100644 --- a/ctdb/server/ctdb_recoverd.c +++ b/ctdb/server/ctdb_recoverd.c @@ -1592,7 +1592,7 @@ static bool ctdb_recovery_lock(struct ctdb_context *ctdb) h = ctdb_cluster_mutex(ctdb, ctdb->recovery_lock, 0); if (h == NULL) { - return -1; + return false; } ctdb_cluster_mutex_set_handler(h, hold_reclock_handler, &s);