aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-12-08 13:34:21 +0100
committerAqua-sama <aqua@iserlohn-fortress.net>2018-12-08 13:34:21 +0100
commit8ec2d92953e3d72664bb9bf545bddaf0c0d851a1 (patch)
treef81ed0e366ca84157d18bbb128fb3a83e0d47b79 /src/main.cpp
parentSplit crash handler code off main (diff)
downloadsmolbote-8ec2d92953e3d72664bb9bf545bddaf0c0d851a1.tar.xz
Fix options not getting overwritten by command line
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/main.cpp b/src/main.cpp
index e718722..d9e1c6a 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -64,13 +64,7 @@ int main(int argc, char **argv)
}
// create and load configuration
- std::unique_ptr<Configuration> config = std::make_unique<Configuration>(nullptr);
- if(!config->parse(cmd->value<std::string>("config").value())) {
- qWarning("Error parsing config file.");
- }
- if(!config->parse(argc, argv)) {
- qWarning("Error parsing command line.");
- }
+ std::unique_ptr<Configuration> config = std::make_unique<Configuration>(argc, argv, cmd->value<std::string>("config").value());
QVector<QPluginLoader *> plugins;
CommandHash_t pluginCommands;