From 7955f134d9e66cc9bbcfc43d30a9eb6a5ac8069a Mon Sep 17 00:00:00 2001 From: Ryszard Rozak Date: Tue, 21 Jan 2025 15:15:08 +0100 Subject: [PATCH] Compare pointers if we dont compare indices Signed-off-by: Ryszard Rozak --- src/VlcSource.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/VlcSource.h b/src/VlcSource.h index 57c1697367..c56501299e 100644 --- a/src/VlcSource.h +++ b/src/VlcSource.h @@ -53,8 +53,8 @@ class VlcSourceCount final { const std::string aWithoutIndex = aStripped.substr(0, aStripped.size() - aIndexLength); const std::string bWithoutIndex = bStripped.substr(0, bStripped.size() - bIndexLength); if (aWithoutIndex != bWithoutIndex) { - // different variables, compare names - return aWithoutIndex < bWithoutIndex; + // different variables, compare pointers + return a < b; } if (aIndexLength == 0 || bIndexLength == 0) { // probably a case like: