From da904316fb2ed4e2d084726e20f514f6faf956f7 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Fri, 22 Sep 2006 11:05:50 +0000 Subject: [PATCH] Add a missing ! to make .. components to behave correctly --- source/path.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/path.cpp b/source/path.cpp index 6127f7a..e79a8fe 100644 --- a/source/path.cpp +++ b/source/path.cpp @@ -155,7 +155,7 @@ void Path::add_component(const string &comp) { unsigned slash=path.rfind(DIRCHAR); unsigned start=(slash==string::npos)?0:slash+1; - if(path.compare(start, string::npos, "..")) + if(!path.compare(start, string::npos, "..")) { // If the last component already is a .., add another path+=DIRCHAR; -- 2.43.0