{"thread":{"id":"984","subject":"[PATCH 4/7] Relaxes error checking in epoch.c to allow duplicate parents","startedAt":"2005-06-20T02:29:33Z","lastAt":"2005-06-20T02:29:33Z","messageCount":1,"participants":["Jon Seymour"],"isPatch":true,"patchVersion":1,"patchTotal":7},"messages":[{"id":"5060","messageId":"20050620022933.28599.qmail@blackcubes.dyndns.org","threadId":"984","inReplyTo":null,"subject":"[PATCH 4/7] Relaxes error checking in epoch.c to allow duplicate parents","fromName":"Jon Seymour","fromEmail":"jon.seymour@gmail.com","sentAt":"2005-06-20T02:29:33Z","receivedAt":"2005-06-20T02:29:33Z","isPatch":true,"sender":{"key":"jon.seymour@gmail.com","avatar":"https://avatars.githubusercontent.com/u/207131?v=4"},"body":"\nGiven that real trees in the wild include parents with duplicate parents, I have relaxed\nover-zealous error checking in epoch.c and dealt with the problem a different way - duplicate\nparents are now silently ignored.\n\nSigned-off-by: Jon Seymour <jon.seymour@gmail.com>\n---\n\n epoch.c |   16 ++++++----------\n 1 files changed, 6 insertions(+), 10 deletions(-)\n\ndiff --git a/epoch.c b/epoch.c\n--- a/epoch.c\n+++ b/epoch.c\n@@ -224,17 +224,13 @@ static int find_base_for_list(struct com\n \tfor (; list; list = list->next) {\n \t\tstruct commit *item = list->item;\n \n-\t\tif (item->object.util) {\n-\t\t\tdie(\"%s:%d:%s: logic error: this should not have happened - commit %s\",\n-\t\t\t    __FILE__, __LINE__, __FUNCTION__,\n-\t\t\t    sha1_to_hex(item->object.sha1));\n-\t\t}\n-\n-\t\tnew_mass_counter(list->item, get_one());\n-\t\tadd(&injected, &injected, get_one());\n+\t\tif (!item->object.util) {\n+\t\t\tnew_mass_counter(list->item, get_one());\n+\t\t\tadd(&injected, &injected, get_one());\n \n-\t\tcommit_list_insert(list->item, &cleaner);\n-\t\tcommit_list_insert(list->item, &pending);\n+\t\t\tcommit_list_insert(list->item, &cleaner);\n+\t\t\tcommit_list_insert(list->item, &pending);\n+\t\t}\n \t}\n \n \twhile (!*boundary && pending && !ret) {\n------------\n"}]}