mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
usb: usb_create() can't fail, drop useless error handling
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
cd2d554127
commit
4806ec9b2c
5 changed files with 1 additions and 18 deletions
|
@ -706,9 +706,6 @@ static USBDevice *usb_msd_init(USBBus *bus, const char *filename)
|
|||
|
||||
/* create guest device */
|
||||
dev = usb_create(bus, "usb-storage");
|
||||
if (!dev) {
|
||||
return NULL;
|
||||
}
|
||||
if (qdev_prop_set_drive(&dev->qdev, "drive",
|
||||
blk_by_legacy_dinfo(dinfo)) < 0) {
|
||||
object_unparent(OBJECT(dev));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue