diff options
| author | Maxime Coste <frrrwww@gmail.com> | 2013-11-16 00:26:56 +0000 |
|---|---|---|
| committer | Maxime Coste <frrrwww@gmail.com> | 2013-11-16 00:26:56 +0000 |
| commit | cb7ef23c442aba45929755694f6c07e4ab1b769b (patch) | |
| tree | 0652e201359b04b4d4ac09c07c80e501df0ece99 /src | |
| parent | 62137f364d6fdc5164da4d518313d21d1c5973f4 (diff) | |
fix invalid value handling for yes no ask options
Diffstat (limited to 'src')
| -rw-r--r-- | src/option_types.hh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/option_types.hh b/src/option_types.hh index a0f14f5c..3d8e7476 100644 --- a/src/option_types.hh +++ b/src/option_types.hh @@ -198,6 +198,8 @@ inline void option_from_string(const String& str, YesNoAsk& opt) opt = No; else if (str == "ask") opt = Ask; + else + throw runtime_error("invalid value '" + str + "', expected yes, no or ask"); } } |
