fp-device: Unref the usb device on finalize
Each device adds a ref to the underlying usb device, but it doesn't remove the reference on finalization. So clear the object to fix the leak
This commit is contained in:
parent
c9216cf96c
commit
71625ec1cf
1 changed files with 1 additions and 0 deletions
|
@ -382,6 +382,7 @@ fp_device_finalize (GObject *object)
|
|||
|
||||
g_clear_pointer (&priv->device_id, g_free);
|
||||
g_clear_pointer (&priv->device_name, g_free);
|
||||
g_clear_object (&priv->usb_device);
|
||||
|
||||
G_OBJECT_CLASS (fp_device_parent_class)->finalize (object);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue