Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 8ee281770f0a
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: c6c9dce655a7
Choose a head ref
  • 2 commits
  • 2 files changed
  • 2 contributors

Commits on Mar 28, 2015

  1. Make Dir raise Errno::EACCES

    The change affects at least Dir.new, Dir.open and Dir.entries.
    Errno::EACCES is now raised unless access to the directory is
    permitted.
    lumeet committed Mar 28, 2015
    Copy the full SHA
    b6750d2 View commit details

Commits on May 1, 2015

  1. Merge pull request #2772 from lumeet/errno_eacces_dir

    Make Dir raise Errno::EACCES
    enebo committed May 1, 2015
    Copy the full SHA
    c6c9dce View commit details
Showing with 1 addition and 1 deletion.
  1. +1 −0 core/src/main/java/org/jruby/RubyDir.java
  2. +0 −1 test/mri/excludes/TestFind.rb
1 change: 1 addition & 0 deletions core/src/main/java/org/jruby/RubyDir.java
Original file line number Diff line number Diff line change
@@ -282,6 +282,7 @@ private static RubyArray entriesCommon(ThreadContext context, String path) {
private static final String[] NO_FILES = new String[] {};
private static String[] getEntries(ThreadContext context, FileResource dir, String path) {
if (!dir.isDirectory()) throw context.runtime.newErrnoENOENTError("No such directory: " + path);
if (!dir.canRead()) throw context.runtime.newErrnoEACCESError(path);

String[] list = dir.list();

1 change: 0 additions & 1 deletion test/mri/excludes/TestFind.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
exclude :test_encoding_non_ascii, ""
exclude :test_unreadable_dir, "not raising EACCESS when trying to find through an unreadable dir"
exclude :test_unsearchable_dir, "fails on travis"