ACK On 17/01/12 12:03 +0100, Fabio M. Di Nitto wrote:
From: "Fabio M. Di Nitto" <fdinitto@xxxxxxxxxx> Signed-off-by: Fabio M. Di Nitto <fdinitto@xxxxxxxxxx> --- :100644 100644 678c295... 4600ed0... M exec/votequorum.c exec/votequorum.c | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/exec/votequorum.c b/exec/votequorum.c index 678c295..4600ed0 100644 --- a/exec/votequorum.c +++ b/exec/votequorum.c @@ -1071,6 +1071,11 @@ static int votequorum_exec_init_fn (struct corosync_api_v1 *api) corosync_api = api; + if (!api) { + LEAVE(); + return (1); + } + list_init(&cluster_members_list); list_init(&trackers_list); @@ -1196,6 +1201,12 @@ cs_error_t votequorum_init(struct corosync_api_v1 *api, { ENTER(); + if ((!api) || (!q_set_quorate_fn)) { + return CS_ERR_INVALID_PARAM; + } + + corosync_api = api; + quorum_callback = q_set_quorate_fn; votequorum_readconfig_static(); -- 1.7.7.5 _______________________________________________ discuss mailing list discuss@xxxxxxxxxxxx http://lists.corosync.org/mailman/listinfo/discuss
_______________________________________________ discuss mailing list discuss@xxxxxxxxxxxx http://lists.corosync.org/mailman/listinfo/discuss