ConfigParser: make the static arrays "const"

This commit is contained in:
Max Kellermann 2014-12-09 21:57:07 +01:00
parent f52aefb341
commit bb39fffab9

View File

@ -23,8 +23,8 @@
bool
get_bool(const char *value, bool *value_r)
{
static const char *t[] = { "yes", "true", "1", nullptr };
static const char *f[] = { "no", "false", "0", nullptr };
static const char *const t[] = { "yes", "true", "1", nullptr };
static const char *const f[] = { "no", "false", "0", nullptr };
if (string_array_contains(t, value)) {
*value_r = true;