X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=src%2Fcputop.c;h=8d4f03e64e8417afde481cb23365af69de4e3658;hb=3439955e838cd626b61ca36e37f80a104966a8fe;hp=c561d47205dd8af3ba8dc192f7da3652c0fe2369;hpb=3ba84bed69e8eb8e6794a7250da97406dbbe02c2;p=lttngtop.git diff --git a/src/cputop.c b/src/cputop.c index c561d47..8d4f03e 100644 --- a/src/cputop.c +++ b/src/cputop.c @@ -45,7 +45,7 @@ void update_cputop_data(unsigned long timestamp, int64_t cpu, int prev_pid, tmpcpu->task_start = timestamp; } -enum bt_cb_ret handle_sched_switch(struct bt_ctf_event *call_data, +enum bt_cb_ret handle_sched_switch(struct ctf_event_definition *call_data, void *private_data) { const struct definition *scope; @@ -99,7 +99,7 @@ error: return BT_CB_ERROR_STOP; } -enum bt_cb_ret handle_sched_process_free(struct bt_ctf_event *call_data, +enum bt_cb_ret handle_sched_process_free(struct ctf_event_definition *call_data, void *private_data) { const struct definition *scope; @@ -120,7 +120,13 @@ enum bt_cb_ret handle_sched_process_free(struct bt_ctf_event *call_data, goto error; } - tid = get_context_tid(call_data); + tid = bt_ctf_get_int64(bt_ctf_get_field(call_data, + scope, "_tid")); + if (bt_ctf_field_get_error()) { + fprintf(stderr, "Missing tid field\n"); + goto error; + } + death_proc(<tngtop, tid, comm, timestamp); return BT_CB_OK;