mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 23:33:54 -06:00
clock: clear callback on unparent
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
a3057c52f4
commit
4cc055039f
3 changed files with 18 additions and 17 deletions
|
@ -87,11 +87,8 @@ void qdev_finalize_clocklist(DeviceState *dev)
|
|||
if (!ncl->output && !ncl->alias) {
|
||||
/*
|
||||
* We kept a reference on the input clock to ensure it lives up to
|
||||
* this point so we can safely remove the callback.
|
||||
* It avoids having a callback to a deleted object if ncl->clock
|
||||
* is still referenced somewhere else (eg: by a clock output).
|
||||
* this point; it is used by the monitor to show the frequency.
|
||||
*/
|
||||
clock_clear_callback(ncl->clock);
|
||||
object_unref(OBJECT(ncl->clock));
|
||||
}
|
||||
g_free(ncl->name);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue