From 64335a6be8463a87841765a515f74164450a7ac8 Mon Sep 17 00:00:00 2001 From: Eric Robinson Date: Wed, 12 Feb 2025 22:45:00 -0500 Subject: [PATCH] Update automap.cpp --- Source/automap.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Source/automap.cpp b/Source/automap.cpp index 8284f8eea41..461d575875e 100644 --- a/Source/automap.cpp +++ b/Source/automap.cpp @@ -1411,11 +1411,10 @@ void DrawAutomapText(const Surface &out) if (gbIsMultiplayer) { if (GameName != "0.0.0.0" && !IsLoopback) { - // Check if GameName is an IP address std::regex ipRegex( - R"((\d{1,3}\.){3}\d{1,3})"); // Basic IPv4 regex (not fully strict) + R"((\d{1,3}\.){3}\d{1,3})"); - if (!std::regex_match(GameName, ipRegex)) { // Only show if not an IP + if (!std::regex_match(GameName, ipRegex)) { std::string description = std::string(_("Game: ")); description.append(GameName); DrawString(out, description, linePosition);