[48/48] usb: fix -usbdevice option handling with no parameters

Submitted by Riku Voipio on March 26, 2010, 4:07 p.m.

Details

Message ID 5039b7b15f2afa964ae86f985683a9fe43f46670.1269617187.git.riku.voipio@nokia.com
State New
Headers show

Commit Message

Riku Voipio March 26, 2010, 4:07 p.m.
From: Juha Riihimäki <juha.riihimaki@nokia.com>

Signed-Off-By: Riku Voipio <riku.voipio@nokia.com>
Signed-off-by: Juha Riihimäki <juha.riihimaki@nokia.com>
---
 hw/usb-bus.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Patch hide | download patch | download mbox

diff --git a/hw/usb-bus.c b/hw/usb-bus.c
index ce8a694..9132d00 100644
--- a/hw/usb-bus.c
+++ b/hw/usb-bus.c
@@ -299,7 +299,7 @@  USBDevice *usbdevice_create(const char *cmdline)
     }
 
     if (!usb->usbdevice_init) {
-        if (params) {
+        if (params && *params) {
             error_report("usbdevice %s accepts no params", driver);
             return NULL;
         }