From: compudj Date: Fri, 6 Apr 2007 03:14:56 +0000 (+0000) Subject: make lttv more robust for kthread creation while state is incomplete X-Git-Tag: v0.12.20~1010 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=61c8808ef2d7a2bc51619b12ae930d476afb0e8e;p=lttv.git make lttv more robust for kthread creation while state is incomplete git-svn-id: http://ltt.polymtl.ca/svn@2479 04897980-b3bd-0310-b5e0-8ef037075253 --- diff --git a/ltt/branches/poly/lttv/lttv/state.c b/ltt/branches/poly/lttv/lttv/state.c index 9f47363e..56784300 100644 --- a/ltt/branches/poly/lttv/lttv/state.c +++ b/ltt/branches/poly/lttv/lttv/state.c @@ -2271,10 +2271,11 @@ static gboolean process_kernel_thread(void *hook_data, void *call_data) LttvExecutionState *es; /* PID */ - pid = ltt_event_get_long_unsigned(e, thf->f1); + pid = (guint)ltt_event_get_long_unsigned(e, thf->f1); s->parent.target_pid = pid; - process = lttv_state_find_process(ts, ANY_CPU, pid); + process = lttv_state_find_process_or_create(ts, ANY_CPU, pid, + <t_time_zero); process->execution_stack = g_array_set_size(process->execution_stack, 1); es = process->state =