summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-04-27 19:58:32 +0200
committerPatric Stout <github@truebrain.nl>2021-04-27 20:18:53 +0200
commit84c75a7b9a8aeb60506454260f9c98454ffb8ab5 (patch)
tree7f642d0196cdf671d659e41a7dd5a43c81b7ed60 /src
parentcb2ef1ea4b74c3d73ba86d978c001784d398bf27 (diff)
downloadopenttd-84c75a7b9a8aeb60506454260f9c98454ffb8ab5.tar.xz
Codechange: be explicit in pointer comparisons
Diffstat (limited to 'src')
-rw-r--r--src/network/core/game_info.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/network/core/game_info.cpp b/src/network/core/game_info.cpp
index bea687af8..b664bb580 100644
--- a/src/network/core/game_info.cpp
+++ b/src/network/core/game_info.cpp
@@ -103,7 +103,7 @@ bool IsNetworkCompatibleVersion(const char *other)
const char *hash1 = ExtractNetworkRevisionHash(GetNetworkRevisionString());
const char *hash2 = ExtractNetworkRevisionHash(other);
- return hash1 && hash2 && (strncmp(hash1, hash2, GITHASH_SUFFIX_LEN) == 0);
+ return hash1 != nullptr && hash2 != nullptr && strncmp(hash1, hash2, GITHASH_SUFFIX_LEN) == 0;
}
/**