mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Merge pull request #15040 from unknownbrackets/path-slashes
Path: Avoid adding a double slash from root
This commit is contained in:
commit
4bd4cde4a2
1 changed files with 1 additions and 1 deletions
|
@ -87,7 +87,7 @@ Path Path::operator /(const std::string &subdir) const {
|
|||
return Path(path_);
|
||||
}
|
||||
std::string fullPath = path_;
|
||||
if (subdir.front() != '/') {
|
||||
if (subdir.front() != '/' && (fullPath.empty() || fullPath.back() != '/')) {
|
||||
fullPath += "/";
|
||||
}
|
||||
fullPath += subdir;
|
||||
|
|
Loading…
Add table
Reference in a new issue