aboutsummaryrefslogtreecommitdiff
path: root/options.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2021-03-02 12:08:34 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2021-03-02 12:08:34 +0000
commitc01251d02388efceca515c47c257e2b5342e3716 (patch)
treeca89407cb43bd2caa40a6854ba49ce1720e892ce /options.c
parent5c275c2a1a963876d4ac392067e42120417dbf43 (diff)
parent1466b570eedda0423d5a386d2b16b7ff0c0e477c (diff)
downloadrtmux-c01251d02388efceca515c47c257e2b5342e3716.tar.gz
rtmux-c01251d02388efceca515c47c257e2b5342e3716.tar.bz2
rtmux-c01251d02388efceca515c47c257e2b5342e3716.zip
Merge branch 'master' into 3.2-rc
Diffstat (limited to 'options.c')
-rw-r--r--options.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/options.c b/options.c
index 09850f7e..9bc89db3 100644
--- a/options.c
+++ b/options.c
@@ -157,8 +157,7 @@ options_value_to_string(struct options_entry *o, union options_value *ov,
case OPTIONS_TABLE_CHOICE:
s = xstrdup(o->tableentry->choices[ov->number]);
break;
- case OPTIONS_TABLE_STRING:
- case OPTIONS_TABLE_COMMAND:
+ default:
fatalx("not a number option type");
}
return (s);
@@ -311,6 +310,8 @@ options_default_to_string(const struct options_table_entry *oe)
case OPTIONS_TABLE_CHOICE:
s = xstrdup(oe->choices[oe->default_num]);
break;
+ default:
+ fatalx("unknown option type");
}
return (s);
}
@@ -703,7 +704,7 @@ options_get_number(struct options *oo, const char *name)
if (o == NULL)
fatalx("missing option %s", name);
if (!OPTIONS_IS_NUMBER(o))
- fatalx("option %s is not a number", name);
+ fatalx("option %s is not a number", name);
return (o->value.number);
}