aboutsummaryrefslogtreecommitdiff
path: root/drivers/windows/dir_access_windows.cpp
diff options
context:
space:
mode:
authorZher Huei Lee2016-03-01 10:40:31 +0000
committerZher Huei Lee2016-03-01 10:40:31 +0000
commitd7052ddba334de3df1190837c6d8589b48799965 (patch)
tree1c53ccbfc0d9edcece7f158d58f25649d0051926 /drivers/windows/dir_access_windows.cpp
parentc0382a1731b2979ad6231720372dc850b2cd4db9 (diff)
downloadgodot-d7052ddba334de3df1190837c6d8589b48799965.tar.gz
godot-d7052ddba334de3df1190837c6d8589b48799965.tar.zst
godot-d7052ddba334de3df1190837c6d8589b48799965.zip
Diffstat (limited to 'drivers/windows/dir_access_windows.cpp')
-rw-r--r--drivers/windows/dir_access_windows.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/windows/dir_access_windows.cpp b/drivers/windows/dir_access_windows.cpp
index 0a413979f..b9476b870 100644
--- a/drivers/windows/dir_access_windows.cpp
+++ b/drivers/windows/dir_access_windows.cpp
@@ -310,8 +310,11 @@ Error DirAccessWindows::rename(String p_path,String p_new_path) {
Error DirAccessWindows::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);
+
printf("erasing %s\n",p_path.utf8().get_data());
//WIN32_FILE_ATTRIBUTE_DATA fileInfo;
//DWORD fileAttr = GetFileAttributesExW(p_path.c_str(), GetFileExInfoStandard, &fileInfo);