]> source.dussan.org Git - jgit.git/commit
ResetCommand: Use DirCacheBuilder in resetIndex 88/8388/2
authorRobin Stocker <robin@nibor.org>
Sun, 28 Oct 2012 14:57:43 +0000 (15:57 +0100)
committerChris Aniszczyk <zx@twitter.com>
Thu, 1 Nov 2012 17:47:10 +0000 (10:47 -0700)
commitde2455af678b5c9d0111336daed1ca0e0958ca01
treef608f31deba41a70e512ec6459c515f1d307dfdd
parent3f1d56d6b7105eec88eea59730a5d78f668df179
ResetCommand: Use DirCacheBuilder in resetIndex

With bug 391855, DirCacheEditor's PathEdit will be applied for each
stage. For an unmerged path, this would result in 3 equal entries for
the same path.

By using a DirCacheBuilder, the code is simpler and does not have the
above problem with unmerged paths.

Bug: 391860
Change-Id: I785deeaeb8474f8c7a7fbc9ef00d3131fac87e41
Signed-off-by: Chris Aniszczyk <zx@twitter.com>
org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java
org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java