summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6ee67f2)
raw | patch | inline | side by side (parent: 6ee67f2)
author | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Mon, 6 Jun 2005 06:32:53 +0000 (23:32 -0700) | ||
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Mon, 6 Jun 2005 06:32:53 +0000 (23:32 -0700) |
Making the main loop look more like the one- and two-way cases
introduced a bug where "src" had been updated early, but later
users hadn't been adjusted to match.
introduced a bug where "src" had been updated early, but later
users hadn't been adjusted to match.
read-tree.c | patch | blob | history |
diff --git a/read-tree.c b/read-tree.c
index 8c9ffe123255bfeb199ea90f055ac8d1df49ddb8..b72ee1c54c092067da0bc35492ae9dead5e990bb 100644 (file)
--- a/read-tree.c
+++ b/read-tree.c
}
if (old && !path_matches(old, ce))
reject_merge(old);
- if (nr > 2 && (result = merge_entries(ce, src[1], src[2])) != NULL) {
+ if (nr > 2 && (result = merge_entries(ce, src[0], src[1])) != NULL) {
result->ce_flags |= htons(CE_UPDATE);
/*
* See if we can re-use the old CE directly?
old = NULL;
}
CHECK_OLD(ce);
+ CHECK_OLD(src[0]);
CHECK_OLD(src[1]);
- CHECK_OLD(src[2]);
ce = result;
ce->ce_flags &= ~htons(CE_STAGEMASK);
src += 2;