diff options
Diffstat (limited to 'hw/ide/qdev.c')
-rw-r--r-- | hw/ide/qdev.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/ide/qdev.c b/hw/ide/qdev.c index 221f387af1..53468edcbc 100644 --- a/hw/ide/qdev.c +++ b/hw/ide/qdev.c @@ -118,7 +118,9 @@ static int ide_drive_initfn(IDEDevice *dev) } } - ide_init_drive(s, dev->conf.bs, dev->version, serial); + if (ide_init_drive(s, dev->conf.bs, dev->version, serial) < 0) { + return -1; + } if (!dev->version) { dev->version = qemu_strdup(s->version); |