mirror of
https://github.com/PixlOne/logiops.git
synced 2025-07-13 21:02:43 +08:00
Merge pull request #346 from ckiee/config-invalid-enforce
logid: Fail on invalid Configurations
This commit is contained in:
commit
fbd915e201
@ -138,9 +138,9 @@ int main(int argc, char** argv) {
|
|||||||
// Read config
|
// Read config
|
||||||
try {
|
try {
|
||||||
config = std::make_shared<Configuration>(options.config_file);
|
config = std::make_shared<Configuration>(options.config_file);
|
||||||
}
|
} catch (std::exception &e) {
|
||||||
catch (std::exception& e) {
|
logPrintf(ERROR, "%s", e.what());
|
||||||
config = std::make_shared<Configuration>();
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
init_workers(config->workers.value_or(defaults::workers));
|
init_workers(config->workers.value_or(defaults::workers));
|
||||||
|
Loading…
Reference in New Issue
Block a user