Handle NULL strings when parsing boolean arguments

This commit is contained in:
Ian Barwick
2018-10-17 11:46:29 +09:00
parent 6999dbb52a
commit ab6c3d9b6e
2 changed files with 3 additions and 2 deletions

View File

@@ -1531,6 +1531,9 @@ parse_bool(const char *s, const char *config_item, ItemList *error_list)
{
PQExpBufferData errors;
if (s == NULL)
return true;
if (strcasecmp(s, "0") == 0)
return false;