Fix incorrect double-retaining of objects on restore.
This commit is contained in:
parent
3678a22c90
commit
290d5d9594
|
@ -116,7 +116,6 @@ object_ref<XEvent> XEvent::Restore(KernelState* kernel_state,
|
||||||
evt->event_->Set();
|
evt->event_->Set();
|
||||||
}
|
}
|
||||||
|
|
||||||
evt->Retain();
|
|
||||||
return object_ref<XEvent>(evt);
|
return object_ref<XEvent>(evt);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1144,7 +1144,7 @@ object_ref<XThread> XThread::Restore(KernelState* kernel_state,
|
||||||
thread->emulator()->debugger()->OnThreadCreated(thread);
|
thread->emulator()->debugger()->OnThreadCreated(thread);
|
||||||
}
|
}
|
||||||
|
|
||||||
return retain_object(thread);
|
return object_ref<XThread>(thread);
|
||||||
}
|
}
|
||||||
|
|
||||||
XHostThread::XHostThread(KernelState* kernel_state, uint32_t stack_size,
|
XHostThread::XHostThread(KernelState* kernel_state, uint32_t stack_size,
|
||||||
|
|
Loading…
Reference in New Issue