Browse Source

Prepend hostname to subsection used to store file timestamp resolution

This ensures the measured filesystem timestamp resolution will be only
used on the machine where it was measured and avoid errors in case the
~/.jgitconfig file is copied to another machine.

Bug: 551850
Change-Id: Iff2a11be62ca94c3bbe4a955182988dc50852f9f
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
stable-5.5
Matthias Sohn 5 years ago
parent
commit
e102bbed99
  1. 5
      org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java

5
org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java

@ -244,8 +244,9 @@ public abstract class FS {
background.set(async); background.set(async);
} }
private static final String javaVersionPrefix = System private static final String javaVersionPrefix = SystemReader
.getProperty("java.vendor") + '|' //$NON-NLS-1$ .getInstance().getHostname() + '|'
+ System.getProperty("java.vendor") + '|' //$NON-NLS-1$
+ System.getProperty("java.version") + '|'; //$NON-NLS-1$ + System.getProperty("java.version") + '|'; //$NON-NLS-1$
private static final Duration FALLBACK_MIN_RACY_INTERVAL = Duration private static final Duration FALLBACK_MIN_RACY_INTERVAL = Duration

Loading…
Cancel
Save