From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NwQKf-0007gh-Jc for qemu-devel@nongnu.org; Mon, 29 Mar 2010 21:33:29 -0400 Received: from [140.186.70.92] (port=50838 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NwQKe-0007fb-5l for qemu-devel@nongnu.org; Mon, 29 Mar 2010 21:33:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NwQKd-0006Mx-1a for qemu-devel@nongnu.org; Mon, 29 Mar 2010 21:33:28 -0400 Received: from mail-pw0-f45.google.com ([209.85.160.45]:51802) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NwQKc-0006Mp-TM for qemu-devel@nongnu.org; Mon, 29 Mar 2010 21:33:27 -0400 Received: by pwi9 with SMTP id 9so8172271pwi.4 for ; Mon, 29 Mar 2010 18:33:25 -0700 (PDT) MIME-Version: 1.0 Date: Tue, 30 Mar 2010 09:33:24 +0800 Message-ID: From: TeLeMan Content-Type: text/plain; charset=UTF-8 Subject: [Qemu-devel] [PATCHv2] usb-bus: fix no params List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel After commit 702f3e0fb52c124c07f215426eeadb70a716643f, the params is nerver NULL. It should check *params instead of params to determine whether the params is empty. Signed-off-by: TeLeMan --- hw/usb-bus.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/usb-bus.c b/hw/usb-bus.c index ce8a694..ee0e9e3 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) { error_report("usbdevice %s accepts no params", driver); return NULL; } -- 1.6.5.1.1367.gcd48 -- SUN OF A BEACH