summaryrefslogtreecommitdiff
path: root/gusb/gusb-interface.c
diff options
context:
space:
mode:
Diffstat (limited to 'gusb/gusb-interface.c')
-rw-r--r--gusb/gusb-interface.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gusb/gusb-interface.c b/gusb/gusb-interface.c
index a7385cd..2aa67df 100644
--- a/gusb/gusb-interface.c
+++ b/gusb/gusb-interface.c
@@ -39,7 +39,8 @@ g_usb_interface_finalize(GObject *object)
{
GUsbInterface *self = G_USB_INTERFACE(object);
- g_bytes_unref(self->extra);
+ if (self->extra != NULL)
+ g_bytes_unref(self->extra);
if (self->endpoints != NULL)
g_ptr_array_unref(self->endpoints);