From: Guilherme Maciel Ferreira Date: Thu, 6 Oct 2011 10:46:49 +0000 (-0300) Subject: There is not possible to pass a NULL value_semantic argument X-Git-Tag: v1.3~11^2~34^2~8 X-Git-Url: http://developer.intra2net.com/git/?a=commitdiff_plain;h=2c531db91ab21983770b385e16f321566fb83f11;p=pingcheck There is not possible to pass a NULL value_semantic argument - For options that do not require arguments (like help, daemon and version), it must be passed an untyped_value object --- diff --git a/src/config/option/configurationoption.cpp b/src/config/option/configurationoption.cpp index c281313..99ad877 100644 --- a/src/config/option/configurationoption.cpp +++ b/src/config/option/configurationoption.cpp @@ -23,6 +23,7 @@ using namespace std; using boost::program_options::option_description; using boost::program_options::option_description; +using boost::program_options::untyped_value; using boost::program_options::value_semantic; using boost::shared_ptr; @@ -40,7 +41,7 @@ ConfigurationOption::ConfigurationOption( const char *command_string, const char *command_description ) : - option( command_string, NULL, command_description ) + option( command_string, new untyped_value(true), command_description ) { }