Log warn if unknown option is found in config file or -i file

pull/43/head
Tatsuhiro Tsujikawa 2013-01-07 22:42:28 +09:00
parent d6000024c0
commit 08bed3f77f
1 changed files with 4 additions and 0 deletions

View File

@ -52,6 +52,8 @@
#include "error_code.h"
#include "prefs.h"
#include "UnknownOptionException.h"
#include "LogFactory.h"
#include "fmt.h"
namespace aria2 {
@ -237,6 +239,8 @@ void OptionParser::parse(Option& option, std::istream& is) const
const OptionHandler* handler = find(pref);
if(handler) {
handler->parse(option, std::string(nv.second.first, nv.second.second));
} else {
A2_LOG_WARN(fmt("Unknown option: %s", line.c_str()));
}
}
}