summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt/Debugger/WatchWidget.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/DolphinQt/Debugger/WatchWidget.cpp')
-rw-r--r--Source/Core/DolphinQt/Debugger/WatchWidget.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Core/DolphinQt/Debugger/WatchWidget.cpp b/Source/Core/DolphinQt/Debugger/WatchWidget.cpp
index 75d3f13ee6..170bfcc792 100644
--- a/Source/Core/DolphinQt/Debugger/WatchWidget.cpp
+++ b/Source/Core/DolphinQt/Debugger/WatchWidget.cpp
@@ -195,10 +195,11 @@ void WatchWidget::Update()
QBrush brush = QPalette().brush(QPalette::Text);
- if (!Core::IsRunning(m_system) || !PowerPC::MMU::HostIsRAMAddress(guard, entry.address))
+ const bool core_is_running = Core::IsRunning(m_system);
+ if (!core_is_running || !PowerPC::MMU::HostIsRAMAddress(guard, entry.address))
brush.setColor(Qt::red);
- if (Core::IsRunning(m_system))
+ if (core_is_running)
{
if (PowerPC::MMU::HostIsRAMAddress(guard, entry.address))
{