env = info->env;
thread_env = env;
info->tid = gettid();
+ env->host_tid = info->tid;
if (info->child_tidptr)
put_user_u32(info->tid, info->child_tidptr);
if (info->parent_tidptr)
/* FIXME: This probably breaks if a signal arrives. We should probably
be disabling signals. */
if (first_cpu->next_cpu) {
+ TaskState *ts;
CPUState **lastp;
CPUState *p;
/* Remove the CPU from the list. */
*lastp = p->next_cpu;
cpu_list_unlock();
- TaskState *ts = ((CPUState *)cpu_env)->opaque;
+ ts = ((CPUState *)cpu_env)->opaque;
if (ts->child_tidptr) {
put_user_u32(0, ts->child_tidptr);
sys_futex(g2h(ts->child_tidptr), FUTEX_WAKE, INT_MAX,