summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFedja Beader <fedja@protonmail.ch>2024-09-20 20:19:56 +0200
committerFedja Beader <fedja@protonmail.ch>2024-09-21 01:36:13 +0200
commit7085c77758e2cb791cba6a4dc41d796a99426b7c (patch)
treedce8ae25c383a39b83edbe7c5c32171fa28ec5dc
parent2aea05c1bf995e9f12f346cea38df9286ef9a502 (diff)
downloadmanaplus-7085c77758e2cb791cba6a4dc41d796a99426b7c.tar.gz
manaplus-7085c77758e2cb791cba6a4dc41d796a99426b7c.tar.bz2
manaplus-7085c77758e2cb791cba6a4dc41d796a99426b7c.tar.xz
manaplus-7085c77758e2cb791cba6a4dc41d796a99426b7c.zip
Remove redundant nullptr check
Curiously, this increases -g -O2 exe size by 96 bytes, but disassembly dump around this code is the same (redundant check was already optimised out?)
-rw-r--r--src/gui/widgets/tabs/chat/chattab.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/widgets/tabs/chat/chattab.cpp b/src/gui/widgets/tabs/chat/chattab.cpp
index 3773df55f..de7944a44 100644
--- a/src/gui/widgets/tabs/chat/chattab.cpp
+++ b/src/gui/widgets/tabs/chat/chattab.cpp
@@ -232,7 +232,7 @@ void ChatTab::chatLog(std::string line,
// if configured, move magic messages log to debug chat tab
if (Net::getNetworkType() == ServerType::TMWATHENA
- && (localChatTab != nullptr) && this == localChatTab
+ && this == localChatTab
&& ((config.getBoolValue("showMagicInDebug")
&& own == ChatMsgType::BY_PLAYER
&& tmp.text.length() > 1