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: f32fb00621ac
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 0279de80e811
Choose a head ref
  • 3 commits
  • 1 file changed
  • 1 contributor

Commits on Mar 15, 2018

  1. Verified

    This commit was signed with the committer’s verified signature.
    headius Charles Oliver Nutter
    Copy the full SHA
    1bf6086 View commit details
  2. Merge branch 'jruby-9.1'

    headius committed Mar 15, 2018
    Copy the full SHA
    ff901a3 View commit details
  3. Copy the full SHA
    0279de8 View commit details
Showing with 4 additions and 7 deletions.
  1. +4 −7 core/src/main/java/org/jruby/RubyFile.java
11 changes: 4 additions & 7 deletions core/src/main/java/org/jruby/RubyFile.java
Original file line number Diff line number Diff line change
@@ -42,6 +42,7 @@
import org.jcodings.specific.UTF8Encoding;
import org.jruby.anno.JRubyClass;
import org.jruby.anno.JRubyMethod;
import org.jruby.exceptions.NotImplementedError;
import org.jruby.exceptions.RaiseException;
import org.jruby.runtime.*;
import org.jruby.runtime.JavaSites.FileSites;
@@ -1191,13 +1192,9 @@ public static IRubyObject utime(ThreadContext context, IRubyObject recv, IRubyOb

try {
result = runtime.getPosix().utimensat(0, fileToTouch.getAbsolutePath(), atimespec, mtimespec, 0);
} catch (RaiseException re) {
if (re.getException().getMetaClass() == runtime.getNotImplementedError()) {
// fall back on utimes
result = runtime.getPosix().utimes(fileToTouch.getAbsolutePath(), atimespec, mtimespec);
} else {
throw re;
}
} catch (NotImplementedError re) {
// fall back on utimes
result = runtime.getPosix().utimes(fileToTouch.getAbsolutePath(), atimespec, mtimespec);
}

if (result == -1) {