From cb7ef23c442aba45929755694f6c07e4ab1b769b Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Sat, 16 Nov 2013 00:26:56 +0000 Subject: [PATCH] fix invalid value handling for yes no ask options --- src/option_types.hh | 2 ++ 1 file changed, 2 insertions(+) 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"); } }