From fe6c2a585a7ba59582723b2fef827dd15bbc8f22 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 19 May 2012 18:54:56 +0300 Subject: Fix code style. --- src/utils/paths.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/utils/paths.cpp') diff --git a/src/utils/paths.cpp b/src/utils/paths.cpp index c00a3f39d..228276efd 100644 --- a/src/utils/paths.cpp +++ b/src/utils/paths.cpp @@ -85,9 +85,7 @@ std::string removeLast(std::string str) if (pos2 == std::string::npos || pos3 > pos2) pos2 = pos3; } - if (pos2 == std::string::npos) - pos2 = -1; - if (pos2 >= 0) + if (pos2 != std::string::npos) return str.substr(0, pos2); else return str; -- cgit v1.2.3-60-g2f50