summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8a1c0d3)
raw | patch | inline | side by side (parent: 8a1c0d3)
author | Junio C Hamano <gitster@pobox.com> | |
Mon, 20 Sep 2010 08:28:35 +0000 (02:28 -0600) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Thu, 30 Sep 2010 00:32:36 +0000 (17:32 -0700) |
In 3734893 (merge-recursive: Fix D/F conflicts 2010-07-09),
process_df_entry() was added to process_renames() and process_entry() but
in a somewhat restrictive manner. Modify the code slightly to make it
clearer how we could chain more such functions if necessary, and alter
process_df_entry() to handle such chaining.
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
process_df_entry() was added to process_renames() and process_entry() but
in a somewhat restrictive manner. Modify the code slightly to make it
clearer how we could chain more such functions if necessary, and alter
process_df_entry() to handle such chaining.
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
merge-recursive.c | patch | blob | history |
diff --git a/merge-recursive.c b/merge-recursive.c
index 51c0536d4e928b7926eef7140a8e03b8ae689de6..7db1538f1296d845b75f168c8de3a3030cf28172 100644 (file)
--- a/merge-recursive.c
+++ b/merge-recursive.c
const char *conf;
struct stat st;
- /* We currently only handle D->F cases */
- assert((!o_sha && a_sha && !b_sha) ||
- (!o_sha && !a_sha && b_sha));
+ if (!((!o_sha && a_sha && !b_sha) || (!o_sha && !a_sha && b_sha)))
+ return 1; /* we don't handle non D-F cases */
entry->processed = 1;
&& !process_df_entry(o, path, e))
clean = 0;
}
+ for (i = 0; i < entries->nr; i++) {
+ struct stage_data *e = entries->items[i].util;
+ if (!e->processed)
+ die("Unprocessed path??? %s",
+ entries->items[i].string);
+ }
string_list_clear(re_merge, 0);
string_list_clear(re_head, 0);