소스 검색

[Fix] make_dir_recursive on Windows

function normally tries to create c: which isn't possible, because the access is denied, handling ERROR_ACCESS_DENIED as ERR_ALREADY_EXISTS lets the function skip the creation of c: .
Roman Nekrassow 10 년 전
부모
커밋
e646fc5b5d
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      drivers/windows/dir_access_windows.cpp

+ 1 - 1
drivers/windows/dir_access_windows.cpp

@@ -270,7 +270,7 @@ Error DirAccessWindows::make_dir(String p_dir) {
 		return OK;
 	};
 
-	if (err == ERROR_ALREADY_EXISTS) {
+	if (err == ERROR_ALREADY_EXISTS || err == ERROR_ACCESS_DENIED) {
 		return ERR_ALREADY_EXISTS;
 	};