summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCache.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCache.java b/org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCache.java
index ce52fedcb3..e00d120735 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCache.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCache.java
@@ -655,8 +655,12 @@ public class DirCache {
final DigestOutputStream dos = new DigestOutputStream(os, foot);
boolean extended = false;
- for (int i = 0; i < entryCnt; i++)
- extended |= sortedEntries[i].isExtended();
+ for (int i = 0; i < entryCnt; i++) {
+ if (sortedEntries[i].isExtended()) {
+ extended = true;
+ break;
+ }
+ }
// Write the header.
//