Avoid `IOError` when returning from `Dir.open`
Ignore `IOError` if `Dir#close` was done in the block.
MODIFY
mrbgems/mruby-dir/mrblib/dir.rb
mrbgems/mruby-dir/mrblib/dir.rb
@@ -36,7 +36,10 @@ class Dir
begin
block.call(d)
ensure
+ begin
d.close
+ rescue IOError
+ end
end
else
self.new(path)

Avoid `IOError` when returning from `Dir.open`

Ignore `IOError` if `Dir#close` was done in the block.