Skip to content

Commit

Permalink
revision.c: reduce odb queries during mark_parents_uninteresting()
Browse files Browse the repository at this point in the history
  • Loading branch information
derrickstolee authored and dscho committed Feb 26, 2018
1 parent 42f530b commit 7cdbbf0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion revision.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,8 @@ void mark_parents_uninteresting(struct commit *commit)
* it is popped next time around, we won't be trying
* to parse it and get an error.
*/
if (!has_object_file(&commit->object.oid))
if (!commit->object.parsed &&
!has_object_file(&commit->object.oid))
commit->object.parsed = 1;

if (commit->object.flags & UNINTERESTING)
Expand Down

0 comments on commit 7cdbbf0

Please sign in to comment.