Added relative paths for DirAccess::remove()
Follows similar behaviour to DirAccess::rename()
(cherry picked from commit d7052ddba3)
This commit is contained in:
committed by
Rémi Verschelde
parent
afd75013f9
commit
c850fa7331
@ -292,8 +292,11 @@ Error DirAccessUnix::rename(String p_path,String p_new_path) {
|
||||
}
|
||||
Error DirAccessUnix::remove(String p_path) {
|
||||
|
||||
p_path=fix_path(p_path);
|
||||
|
||||
if (p_path.is_rel_path())
|
||||
p_path=get_current_dir().plus_file(p_path);
|
||||
else
|
||||
p_path=fix_path(p_path);
|
||||
|
||||
struct stat flags;
|
||||
if ((stat(p_path.utf8().get_data(),&flags)!=0))
|
||||
return FAILED;
|
||||
|
||||
Reference in New Issue
Block a user