mirror of https://github.com/PentHertz/srsLTE.git
Making sure errors in the enb.conf is handled gracefully
This commit is contained in:
parent
1bac758a85
commit
435d63b871
|
@ -212,8 +212,15 @@ void parse_args(all_args_t *args, int argc, char* argv[]) {
|
|||
cout << "Failed to read configuration file " << config_file << " - exiting" << endl;
|
||||
exit(1);
|
||||
}
|
||||
bpo::store(bpo::parse_config_file(conf, common), vm);
|
||||
bpo::notify(vm);
|
||||
|
||||
// parse config file and handle errors gracefully
|
||||
try {
|
||||
bpo::store(bpo::parse_config_file(conf, common), vm);
|
||||
bpo::notify(vm);
|
||||
} catch (const boost::program_options::error& e) {
|
||||
cerr << e.what() << endl;
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Convert hex strings
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue