summaryrefslogtreecommitdiff
path: root/src/utils/paths.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-05-19 18:54:56 +0300
committerAndrei Karas <akaras@inbox.ru>2012-05-19 18:54:56 +0300
commitfe6c2a585a7ba59582723b2fef827dd15bbc8f22 (patch)
treed2e1c9015084f4d99474babd00df0d8974eea498 /src/utils/paths.cpp
parent804154afbee8843dde358837ec18ab7bfb785088 (diff)
downloadmanaverse-fe6c2a585a7ba59582723b2fef827dd15bbc8f22.tar.gz
manaverse-fe6c2a585a7ba59582723b2fef827dd15bbc8f22.tar.bz2
manaverse-fe6c2a585a7ba59582723b2fef827dd15bbc8f22.tar.xz
manaverse-fe6c2a585a7ba59582723b2fef827dd15bbc8f22.zip
Fix code style.
Diffstat (limited to 'src/utils/paths.cpp')
-rw-r--r--src/utils/paths.cpp4
1 files changed, 1 insertions, 3 deletions
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;