summaryrefslogtreecommitdiff
path: root/builtin-merge.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-08-20 22:09:28 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-08-20 22:49:21 (GMT)
commit9ca8f6079cdb199851636c719900472a9745885f (patch)
tree0647b366e94f239e4485ee9ed6eafe8e9d63dd87 /builtin-merge.c
parent25b3d4d6f39d70c4d46dee48570ae7aeeb4a6b58 (diff)
downloadgit-9ca8f6079cdb199851636c719900472a9745885f.zip
git-9ca8f6079cdb199851636c719900472a9745885f.tar.gz
git-9ca8f6079cdb199851636c719900472a9745885f.tar.bz2
"git-merge": allow fast-forwarding in a stat-dirty tree
We used to refresh the index to clear stat-dirtyness before a fast-forward merge. Recent C rewrite forgot to do this. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-merge.c')
-rw-r--r--builtin-merge.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin-merge.c b/builtin-merge.c
index dde0c7e..a201c66 100644
--- a/builtin-merge.c
+++ b/builtin-merge.c
@@ -566,6 +566,7 @@ static int checkout_fast_forward(unsigned char *head, unsigned char *remote)
if (read_cache_unmerged())
die("you need to resolve your current index first");
+ refresh_cache(REFRESH_QUIET);
fd = hold_locked_index(lock_file, 1);
@@ -936,7 +937,6 @@ int cmd_merge(int argc, const char **argv, const char *prefix)
hex,
find_unique_abbrev(remoteheads->item->object.sha1,
DEFAULT_ABBREV));
- refresh_cache(REFRESH_QUIET);
strbuf_init(&msg, 0);
strbuf_addstr(&msg, "Fast forward");
if (have_message)