[PATCH spice-gtk 04/44] fixup! usb-redir: define interfaces to support emulated devices

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Free libusb_device and edev anyway, even if they should be
exclusively set
---
 src/usb-backend.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/usb-backend.c b/src/usb-backend.c
index ec0ae3e8..0b37274e 100644
--- a/src/usb-backend.c
+++ b/src/usb-backend.c
@@ -543,7 +543,8 @@ void spice_usb_backend_device_unref(SpiceUsbBackendDevice *dev)
         if (dev->libusb_device) {
             libusb_unref_device(dev->libusb_device);
             LOUD_DEBUG("%s freeing %p (libusb %p)", __FUNCTION__, dev, dev->libusb_device);
-        } else if (dev->edev) {
+        }
+        if (dev->edev) {
             device_ops(dev->edev)->delete(dev->edev);
         }
         g_free(dev);
-- 
2.20.1

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]