diff --git a/Common/File/Path.cpp b/Common/File/Path.cpp index a3d773f740..b9db9aba2c 100644 --- a/Common/File/Path.cpp +++ b/Common/File/Path.cpp @@ -320,7 +320,7 @@ bool Path::CanNavigateUp() const { } if (type_ == PathType::HTTP) { size_t rootSlash = path_.find_first_of('/', strlen("https://")); - if (rootSlash == path_.npos || path_.size() < rootSlash + 1) { + if (rootSlash == path_.npos || path_.size() == rootSlash + 1) { // This means, "http://server" or "http://server/". Can't go up. return false; }