diff options
Diffstat (limited to 'gcc/ada/g-dirope.adb')
-rw-r--r-- | gcc/ada/g-dirope.adb | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/gcc/ada/g-dirope.adb b/gcc/ada/g-dirope.adb index 33086ed1766..c7670ef558b 100644 --- a/gcc/ada/g-dirope.adb +++ b/gcc/ada/g-dirope.adb @@ -739,9 +739,7 @@ package body GNAT.Directory_Operations is -- Remove the directory only if it is empty if not Recursive then - rmdir (C_Dir_Name); - - if GNAT.OS_Lib.Is_Directory (Dir_Name) then + if rmdir (C_Dir_Name) /= 0 then raise Directory_Error; end if; @@ -764,7 +762,6 @@ package body GNAT.Directory_Operations is Str (1 .. Last) /= ".." then Remove_Dir (Str (1 .. Last), True); - Remove_Dir (Str (1 .. Last)); end if; else |