From 8ad3c6bbb4556332c5a6b7fecdab73310c045b24 Mon Sep 17 00:00:00 2001 From: Jan Friesse Date: Mon, 25 Nov 2019 18:21:52 +0100 Subject: [PATCH] votequorum: Ignore the icmap_get_* return value Express intention to ignore icmap_get_* return value and rely on default behavior of not changing the output parameter on error. Signed-off-by: Jan Friesse (cherry picked from commit cddd62f972bca276c934e58f08da84071cec1ddb) --- exec/votequorum.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/exec/votequorum.c b/exec/votequorum.c index 49bcdfa..e3cb7eb 100644 --- a/exec/votequorum.c +++ b/exec/votequorum.c @@ -1272,10 +1272,10 @@ static char *votequorum_readconfig(int runtime) /* * gather basic data here */ - icmap_get_uint32("quorum.expected_votes", &expected_votes); + (void)icmap_get_uint32("quorum.expected_votes", &expected_votes); have_nodelist = votequorum_read_nodelist_configuration(&node_votes, &node_count, &node_expected_votes); have_qdevice = votequorum_qdevice_is_configured(&qdevice_votes); - icmap_get_uint8("quorum.two_node", &two_node); + (void)icmap_get_uint8("quorum.two_node", &two_node); /* * do config verification and enablement @@ -1320,13 +1320,13 @@ static char *votequorum_readconfig(int runtime) wait_for_all = 1; } - icmap_get_uint8("quorum.allow_downscale", &allow_downscale); - icmap_get_uint8("quorum.wait_for_all", &wait_for_all); - icmap_get_uint8("quorum.last_man_standing", &last_man_standing); - icmap_get_uint32("quorum.last_man_standing_window", &last_man_standing_window); - icmap_get_uint8("quorum.expected_votes_tracking", &ev_tracking); - icmap_get_uint8("quorum.auto_tie_breaker", &atb); - icmap_get_string("quorum.auto_tie_breaker_node", &atb_string); + (void)icmap_get_uint8("quorum.allow_downscale", &allow_downscale); + (void)icmap_get_uint8("quorum.wait_for_all", &wait_for_all); + (void)icmap_get_uint8("quorum.last_man_standing", &last_man_standing); + (void)icmap_get_uint32("quorum.last_man_standing_window", &last_man_standing_window); + (void)icmap_get_uint8("quorum.expected_votes_tracking", &ev_tracking); + (void)icmap_get_uint8("quorum.auto_tie_breaker", &atb); + (void)icmap_get_string("quorum.auto_tie_breaker_node", &atb_string); /* auto_tie_breaker defaults to LOWEST */ if (atb) { @@ -1518,7 +1518,7 @@ static char *votequorum_readconfig(int runtime) us->expected_votes = node_expected_votes; } else { us->votes = 1; - icmap_get_uint32("quorum.votes", &us->votes); + (void)icmap_get_uint32("quorum.votes", &us->votes); } if (expected_votes) { @@ -1569,7 +1569,7 @@ static void votequorum_refresh_config( return ; } - icmap_get_uint8("quorum.cancel_wait_for_all", &cancel_wfa); + (void)icmap_get_uint8("quorum.cancel_wait_for_all", &cancel_wfa); if (strcmp(key_name, "quorum.cancel_wait_for_all") == 0 && cancel_wfa >= 1) { icmap_set_uint8("quorum.cancel_wait_for_all", 0); -- 1.8.3.1