aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorEd Maste <emaste@freebsd.org>2013-05-07 10:06:12 -0400
committerGerd Hoffmann <kraxel@redhat.com>2013-06-03 07:17:12 +0200
commit45ec267160307ce2ca7494d942589ba222b29479 (patch)
treedb99f65b7f26982da76e8d09178825a46574f58e /hw
parent756335292f2b46775992c314cc70b54480a46d26 (diff)
downloadqemu-45ec267160307ce2ca7494d942589ba222b29479.zip
qemu-45ec267160307ce2ca7494d942589ba222b29479.tar.gz
qemu-45ec267160307ce2ca7494d942589ba222b29479.tar.bz2
host-libusb: Correct test for USB packet state
USB_RET_ASYNC is -6, so inflight was always false. Signed-off-by: Ed Maste <emaste@freebsd.org> Cc: qemu-stable@nongnu.org Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/usb/host-libusb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/usb/host-libusb.c b/hw/usb/host-libusb.c
index f3de459..3a582c5 100644
--- a/hw/usb/host-libusb.c
+++ b/hw/usb/host-libusb.c
@@ -385,7 +385,7 @@ out:
static void usb_host_req_abort(USBHostRequest *r)
{
USBHostDevice *s = r->host;
- bool inflight = (r->p && r->p->state == USB_RET_ASYNC);
+ bool inflight = (r->p && r->p->state == USB_PACKET_ASYNC);
if (inflight) {
r->p->status = USB_RET_NODEV;