Browse Source

dfs: Fix incorrect use of reference == for DfsStreamKey

Must use .equals() now with DfsStreamKey.

Change-Id: I35fecbe3895c2078d69213e9c708a9b0613a1c7c
stable-4.9
Shawn Pearce 7 years ago
parent
commit
a6afed9bb8
  1. 2
      org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java

2
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java

@ -74,7 +74,7 @@ final class DfsBlock {
}
boolean contains(DfsStreamKey want, long pos) {
return stream == want && start <= pos && pos < end;
return stream.equals(want) && start <= pos && pos < end;
}
int copy(long pos, byte[] dstbuf, int dstoff, int cnt) {

Loading…
Cancel
Save