diff options
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java b/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java index dba89709aa..8e70f57fa3 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java @@ -350,15 +350,8 @@ public class ResolveMerger extends ThreeWayMerger { while(mpathsIt.hasNext()) { String mpath=mpathsIt.next(); DirCacheEntry entry = dc.getEntry(mpath); - if (entry == null) - continue; - FileOutputStream fos = new FileOutputStream(new File( - db.getWorkTree(), mpath)); - try { - reader.open(entry.getObjectId()).copyTo(fos); - } finally { - fos.close(); - } + if (entry != null) + DirCacheCheckout.checkoutEntry(db, entry, reader); mpathsIt.remove(); } } |