From 739d14ad7a3e19b035b87a2d2c57184e083e1f6e Mon Sep 17 00:00:00 2001 From: Juha Reunanen Date: Fri, 27 Sep 2024 17:22:04 +0300 Subject: [PATCH] Avoid a compiler warning, and while at it hopefully fix the code so that it does what it was supposed to do in the first place --- src/protocol/string_utils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/protocol/string_utils.cpp b/src/protocol/string_utils.cpp index 217a6ab4..18c42ea3 100644 --- a/src/protocol/string_utils.cpp +++ b/src/protocol/string_utils.cpp @@ -800,7 +800,7 @@ std::string GetNodeField(const std::string & data, const char * field) if (semicolon == std::string::npos) { - data.substr(colon); + return data.substr(colon); } return data.substr(colon, semicolon - colon);