File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -236,8 +236,8 @@ struct
236236 (* temporary workaround for dir-to-empty-target-dir https://github.com/ocaml/ocaml/issues/12073 *)
237237 if Sys. win32 && path_is_an_empty_dir fs new_path then fs else
238238 (* temporary workaround for dir-to-file https://github.com/ocaml/ocaml/issues/12073 *)
239- if (Sys. win32 && path_is_file fs new_path) then
240- (match Model. separate_path new_path in
239+ if (Sys. win32 && path_is_a_file fs new_path) then
240+ (match Model. separate_path new_path with
241241 | None -> fs
242242 | Some (new_path_pref , new_name ) ->
243243 let fs = remove fs new_path_pref new_name in
@@ -334,7 +334,7 @@ struct
334334 List. exists (path_is_a_file fs) (path_prefixes old_path) ||
335335 List. exists (path_is_a_file fs) (path_prefixes new_path) ||
336336 path_is_a_dir fs old_path && Model. mem fs new_path && not (path_is_a_dir fs new_path)) ||
337- (s = " Is a directory" && path_is_a_dir fs new_path) ||
337+ (( s = " Is a directory" || s = " Permission denied " ) && path_is_a_dir fs new_path) ||
338338 (s = " Directory not empty" &&
339339 is_true_prefix new_path old_path || (path_is_a_dir fs new_path && not (path_is_an_empty_dir fs new_path)))
340340 | Error _ -> false )
You can’t perform that action at this time.
0 commit comments