From 1e6507d7928f1ebd24bd127bb26451c64c971ea7 Mon Sep 17 00:00:00 2001 From: Vitor K Date: Sun, 20 Nov 2022 22:41:33 -0300 Subject: [PATCH] Resolve C4101 warning and catch logic_error instead of exception, as stoll should only throw std::invalid_argument and std::out_of_range, and both inherit from it. --- src/citra/config.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/citra/config.cpp b/src/citra/config.cpp index 18e0ad2e8..eaa5aeb5a 100644 --- a/src/citra/config.cpp +++ b/src/citra/config.cpp @@ -262,7 +262,7 @@ void Config::ReadValues() { try { days = std::stoll(day_string); - } catch (std::exception& e) { + } catch (std::logic_error&) { LOG_ERROR(Config, "Failed to parse days in init_time_offset. Using 0"); days = 0; }