summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2018-10-16 16:16:08 +0900
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-10-16 16:16:08 +0900
commit488e2e8ff53091669988cbec7fe29abb08aea406 (patch)
tree776bd4755678151550b34bbbef8f717105d2615b
parentMerge branch 'jk/oideq-hasheq-cleanup' (diff)
parentsequencer: use return value of oidset_insert() (diff)
downloadtgif-488e2e8ff53091669988cbec7fe29abb08aea406.tar.xz
Merge branch 'rs/sequencer-oidset-insert-avoids-dups'
Code clean-up. * rs/sequencer-oidset-insert-avoids-dups: sequencer: use return value of oidset_insert()
-rw-r--r--sequencer.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sequencer.c b/sequencer.c
index ddb41a62d9..6387c9ee6e 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -4146,9 +4146,7 @@ static int make_script_with_merges(struct pretty_print_context *pp,
struct object_id *oid = &parent->item->object.oid;
if (!oidset_contains(&interesting, oid))
continue;
- if (!oidset_contains(&child_seen, oid))
- oidset_insert(&child_seen, oid);
- else
+ if (oidset_insert(&child_seen, oid))
label_oid(oid, "branch-point", &state);
}