aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/src/org
diff options
context:
space:
mode:
authorStefan Lay <stefan.lay@sap.com>2013-11-27 17:10:39 +0100
committerGerrit Code Review @ Eclipse.org <gerrit@eclipse.org>2013-11-29 10:36:53 -0500
commitdcd0dd4d9ec0ffebb5bdbbe9ea819316427b79ca (patch)
treec252c6b0f8aa0fcbdef5251b86eb7862e5adc897 /org.eclipse.jgit/src/org
parentec0d78d0939ee8ce30bd349bd885186c13d3b645 (diff)
downloadjgit-dcd0dd4d9ec0ffebb5bdbbe9ea819316427b79ca.tar.gz
jgit-dcd0dd4d9ec0ffebb5bdbbe9ea819316427b79ca.zip
Fix applying stash on other commit
Applying a stash on another commit failed because the merge base for the cherry-pick of the stashed index state was not corectly set. Bug: 422684 Change-Id: I9355352b2b9a7abefa3248ca3c17a9301177d0d6 Signed-off-by: Stefan Lay <stefan.lay@sap.com>
Diffstat (limited to 'org.eclipse.jgit/src/org')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/api/StashApplyCommand.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashApplyCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashApplyCommand.java
index 020a6dc5f2..73d64529b3 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashApplyCommand.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashApplyCommand.java
@@ -185,6 +185,7 @@ public class StashApplyCommand extends GitCommand<ObjectId> {
.newMerger(repo, true);
ixMerger.setCommitNames(new String[] { "stashed HEAD",
"HEAD", "stashed index" });
+ ixMerger.setBase(stashHeadCommit);
boolean ok = ixMerger.merge(headCommit, stashIndexCommit);
if (ok) {
resetIndex(revWalk