X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=commit.c;h=73b7e00292ba2de33fa43b5f028fd807a460af34;hb=dbdc07fcbe3a951df8a3869b42edb6fffd466486;hp=9f4cc636dd74e99a1311500e15501bdb4875cb9d;hpb=ffa4c364f4ec090438de48a986f02cdeb302b46c;p=git.git diff --git a/commit.c b/commit.c index 9f4cc636d..73b7e0029 100644 --- a/commit.c +++ b/commit.c @@ -442,6 +442,20 @@ void clear_commit_marks(struct commit *commit, unsigned int mark) } } +void clear_commit_marks_for_object_array(struct object_array *a, unsigned mark) +{ + struct object *object; + struct commit *commit; + unsigned int i; + + for (i = 0; i < a->nr; i++) { + object = a->objects[i].item; + commit = lookup_commit_reference_gently(object->sha1, 1); + if (commit) + clear_commit_marks(commit, mark); + } +} + struct commit *pop_commit(struct commit_list **stack) { struct commit_list *top = *stack;