diff --git a/ChangeLog b/ChangeLog index 6ef301de82..50650a4347 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +Fri Apr 25 22:54:34 2014 Naohisa Goto + + * lib/fileutils.rb (rmdir): rescue Errno::EEXIST in addition to + ENOTEMPTY (and ENOENT), because SUSv3 describes that "If the + directory is not an empty directory, rmdir() shall fail and set + errno to [EEXIST] or [ENOTEMPTY]" and Solaris uses EEXIST. + [Bug #9571] [ruby-dev:48017] + Fri Apr 25 19:16:30 2014 Tanaka Akira * lib/webrick/utils.rb: Don't rescue LoadError for 'etc' extension. diff --git a/lib/fileutils.rb b/lib/fileutils.rb index 0dfbf41d6c..6d1f2764fa 100644 --- a/lib/fileutils.rb +++ b/lib/fileutils.rb @@ -277,7 +277,7 @@ module FileUtils Dir.rmdir(dir) end end - rescue Errno::ENOTEMPTY, Errno::ENOENT + rescue Errno::ENOTEMPTY, Errno::EEXIST, Errno::ENOENT end end end