summaryrefslogtreecommitdiff
path: root/src/core/frontend
diff options
context:
space:
mode:
authorGravatar bunnei2020-12-08 21:58:13 -0800
committerGravatar GitHub2020-12-08 21:58:13 -0800
commit6f41763061082d5fa2ab039c554427152243cb46 (patch)
tree158dde17ce9426c21c727f03a6e8651b09a2dade /src/core/frontend
parentMerge pull request #5135 from Morph1984/applets-shadow (diff)
parentcore: Remove unnecessary enum casts in log calls (diff)
downloadyuzu-6f41763061082d5fa2ab039c554427152243cb46.tar.gz
yuzu-6f41763061082d5fa2ab039c554427152243cb46.tar.xz
yuzu-6f41763061082d5fa2ab039c554427152243cb46.zip
Merge pull request #5166 from lioncash/log-cast
core: Remove unnecessary enum casts in log calls
Diffstat (limited to 'src/core/frontend')
-rw-r--r--src/core/frontend/applets/error.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/frontend/applets/error.cpp b/src/core/frontend/applets/error.cpp
index 4002a9211..dceb20ff8 100644
--- a/src/core/frontend/applets/error.cpp
+++ b/src/core/frontend/applets/error.cpp
@@ -2,6 +2,7 @@
2// Licensed under GPLv2 or any later version 2// Licensed under GPLv2 or any later version
3// Refer to the license.txt file included. 3// Refer to the license.txt file included.
4 4
5#include "common/logging/log.h"
5#include "core/frontend/applets/error.h" 6#include "core/frontend/applets/error.h"
6 7
7namespace Core::Frontend { 8namespace Core::Frontend {
@@ -10,7 +11,7 @@ ErrorApplet::~ErrorApplet() = default;
10 11
11void DefaultErrorApplet::ShowError(ResultCode error, std::function<void()> finished) const { 12void DefaultErrorApplet::ShowError(ResultCode error, std::function<void()> finished) const {
12 LOG_CRITICAL(Service_Fatal, "Application requested error display: {:04}-{:04} (raw={:08X})", 13 LOG_CRITICAL(Service_Fatal, "Application requested error display: {:04}-{:04} (raw={:08X})",
13 static_cast<u32>(error.module.Value()), error.description.Value(), error.raw); 14 error.module.Value(), error.description.Value(), error.raw);
14} 15}
15 16
16void DefaultErrorApplet::ShowErrorWithTimestamp(ResultCode error, std::chrono::seconds time, 17void DefaultErrorApplet::ShowErrorWithTimestamp(ResultCode error, std::chrono::seconds time,
@@ -18,7 +19,7 @@ void DefaultErrorApplet::ShowErrorWithTimestamp(ResultCode error, std::chrono::s
18 LOG_CRITICAL( 19 LOG_CRITICAL(
19 Service_Fatal, 20 Service_Fatal,
20 "Application requested error display: {:04X}-{:04X} (raw={:08X}) with timestamp={:016X}", 21 "Application requested error display: {:04X}-{:04X} (raw={:08X}) with timestamp={:016X}",
21 static_cast<u32>(error.module.Value()), error.description.Value(), error.raw, time.count()); 22 error.module.Value(), error.description.Value(), error.raw, time.count());
22} 23}
23 24
24void DefaultErrorApplet::ShowCustomErrorText(ResultCode error, std::string main_text, 25void DefaultErrorApplet::ShowCustomErrorText(ResultCode error, std::string main_text,
@@ -26,7 +27,7 @@ void DefaultErrorApplet::ShowCustomErrorText(ResultCode error, std::string main_
26 std::function<void()> finished) const { 27 std::function<void()> finished) const {
27 LOG_CRITICAL(Service_Fatal, 28 LOG_CRITICAL(Service_Fatal,
28 "Application requested custom error with error_code={:04X}-{:04X} (raw={:08X})", 29 "Application requested custom error with error_code={:04X}-{:04X} (raw={:08X})",
29 static_cast<u32>(error.module.Value()), error.description.Value(), error.raw); 30 error.module.Value(), error.description.Value(), error.raw);
30 LOG_CRITICAL(Service_Fatal, " Main Text: {}", main_text); 31 LOG_CRITICAL(Service_Fatal, " Main Text: {}", main_text);
31 LOG_CRITICAL(Service_Fatal, " Detail Text: {}", detail_text); 32 LOG_CRITICAL(Service_Fatal, " Detail Text: {}", detail_text);
32} 33}