Clean up calls to repmgr_atoi()

In some places we were still providing "false" from the original implementation,
which was intended to indicate whether a negative value was allowed.

This has not been a problem, as it merely means we have been providing "0",
which is the same thing; however we can finer-tune some of the calls
(e.g. node ID must be or greater).
This commit is contained in:
Ian Barwick
2019-01-30 11:43:43 +09:00
parent b6264b77c4
commit 70e4243a1d
3 changed files with 15 additions and 16 deletions

View File

@@ -473,7 +473,7 @@ _parse_config(t_configuration_options *options, ItemList *error_list, ItemList *
/* Copy into correct entry in parameters struct */
if (strcmp(name, "node_id") == 0)
{
options->node_id = repmgr_atoi(value, name, error_list, 1);
options->node_id = repmgr_atoi(value, name, error_list, MIN_NODE_ID);
node_id_found = true;
}
else if (strcmp(name, "node_name") == 0)