aboutsummaryrefslogtreecommitdiff
path: root/hw/usb/dev-uas.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2021-12-10 09:06:59 +0100
committerGerd Hoffmann <kraxel@redhat.com>2022-01-13 10:58:05 +0100
commit1c6c0b9ec1c0d980d4f0ac2604c4f9fd9611034b (patch)
tree54db26545b03764bc9d4e290d917f2ff3b7a34ae /hw/usb/dev-uas.c
parent87800d940584cb22fbfa1a0da61f2365e6ede3a8 (diff)
downloadqemu-1c6c0b9ec1c0d980d4f0ac2604c4f9fd9611034b.zip
qemu-1c6c0b9ec1c0d980d4f0ac2604c4f9fd9611034b.tar.gz
qemu-1c6c0b9ec1c0d980d4f0ac2604c4f9fd9611034b.tar.bz2
uas: add missing return
Otherwise we run the error handling code even for successful requests. Fixes: 13b250b12ad3 ("uas: add stream number sanity checks.") Reported-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211210080659.2537084-1-kraxel@redhat.com>
Diffstat (limited to 'hw/usb/dev-uas.c')
-rw-r--r--hw/usb/dev-uas.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/usb/dev-uas.c b/hw/usb/dev-uas.c
index 599d6b5..c9f295e 100644
--- a/hw/usb/dev-uas.c
+++ b/hw/usb/dev-uas.c
@@ -908,6 +908,7 @@ static void usb_uas_handle_data(USBDevice *dev, USBPacket *p)
p->status = USB_RET_STALL;
break;
}
+ return;
err_stream:
error_report("%s: invalid stream %d", __func__, p->stream);