Fix error when using 2 or more slashes on resource path

This commit is contained in:
volzhs 2016-09-30 03:11:45 +09:00
parent 20c7b65b7e
commit 0866f49f4e

View File

@ -3073,6 +3073,11 @@ String String::simplify_path() const {
}
s =s.replace("\\","/");
while(true){ // in case of using 2 or more slash
String compare = s.replace("//","/");
if (s==compare) break;
else s=compare;
}
Vector<String> dirs = s.split("/",false);
for(int i=0;i<dirs.size();i++) {