From 1a39f9ddc04f4d15685c140236ebb52155105ff3 Mon Sep 17 00:00:00 2001 From: mlangkabel Date: Tue, 4 Sep 2018 21:43:00 +0200 Subject: [PATCH] logic: fixed crash and missing includes in LogMemoryStringMap --- src/lib/utility/LowMemoryStringMap.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/utility/LowMemoryStringMap.h b/src/lib/utility/LowMemoryStringMap.h index d4286712..b68b94f7 100644 --- a/src/lib/utility/LowMemoryStringMap.h +++ b/src/lib/utility/LowMemoryStringMap.h @@ -4,6 +4,7 @@ #include #include #include +#include /* * StringTraits @@ -398,7 +399,7 @@ private: std::unique_ptr child = std::move(it->second); StringT childStr = child->getString(); - auto p = std::mismatch(childStr.begin(), childStr.end(), str.begin() + idx); + auto p = std::mismatch(childStr.begin(), childStr.end(), str.begin() + idx, str.end()); if (p.first == childStr.end() && p.second == str.end()) {