I noticed an error in the documentation. In th "Introduction", go at the "Put it all together" section and search for the following code:
- Code: Select all
void defineOptions(OptionSet& options)
{
ServerApplication::defineOptions(options);
options.addOption(
Option("help", "h", "display argument help information")
.required(false)
.repeatable(false)
.callback(OptionCallback(
this, &SampleApp::handleHelp)));
}
The "&SampleApp" is a reference to an object of a non existing type. I guess that first you called the application "SampleApp" instead of "HTTPTimeServer". I changed this reference with a "&HTTPTimeServer" and everything worked fine! ;-)
Hope this helps,
petrux





