From 2afaa5e8df826d29e46de175b535d410ceee1aa5 Mon Sep 17 00:00:00 2001 From: Oliver Hamlet Date: Thu, 5 Jan 2017 20:19:08 +0000 Subject: [PATCH] Fix startup crash if no games are detected --- src/backend/app/loot_state.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/app/loot_state.cpp b/src/backend/app/loot_state.cpp index 74328e49..9a02f9c2 100644 --- a/src/backend/app/loot_state.cpp +++ b/src/backend/app/loot_state.cpp @@ -182,6 +182,7 @@ void LootState::init(const std::string& cmdLineGame) { try { BOOST_LOG_TRIVIAL(debug) << "Selecting game."; selectGame(cmdLineGame); + BOOST_LOG_TRIVIAL(debug) << "Game selected is " << currentGame_->Name(); BOOST_LOG_TRIVIAL(debug) << "Initialising game-specific settings."; currentGame_->Init(true); // Update game path in settings object. @@ -190,7 +191,6 @@ void LootState::init(const std::string& cmdLineGame) { BOOST_LOG_TRIVIAL(error) << "Game-specific settings could not be initialised. " << e.what(); initErrors_.push_back((format(translate("Error: Game-specific settings could not be initialised. %1%")) % e.what()).str()); } - BOOST_LOG_TRIVIAL(debug) << "Game selected is " << currentGame_->Name(); } const std::vector& LootState::getInitErrors() const {