Browse Source

maintenance: add trace2 regions for task execution

Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
Derrick Stolee 4 years ago committed by Junio C Hamano
parent
commit
25914c4fde
  1. 2
      builtin/gc.c

2
builtin/gc.c

@ -927,10 +927,12 @@ static int maintenance_run_tasks(struct maintenance_run_opts *opts) @@ -927,10 +927,12 @@ static int maintenance_run_tasks(struct maintenance_run_opts *opts)
!tasks[i].auto_condition()))
continue;

trace2_region_enter("maintenance", tasks[i].name, r);
if (tasks[i].fn(opts)) {
error(_("task '%s' failed"), tasks[i].name);
result = 1;
}
trace2_region_leave("maintenance", tasks[i].name, r);
}

rollback_lock_file(&lk);

Loading…
Cancel
Save