aboutsummaryrefslogtreecommitdiff
path: root/hw/core/qdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/core/qdev.c')
-rw-r--r--hw/core/qdev.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/hw/core/qdev.c b/hw/core/qdev.c
index 35fd00d26c..901f289860 100644
--- a/hw/core/qdev.c
+++ b/hw/core/qdev.c
@@ -1141,9 +1141,7 @@ static void device_finalize(Object *obj)
NamedGPIOList *ngl, *next;
DeviceState *dev = DEVICE(obj);
- if (dev->opts) {
- qemu_opts_del(dev->opts);
- }
+ qemu_opts_del(dev->opts);
QLIST_FOREACH_SAFE(ngl, &dev->gpios, node, next) {
QLIST_REMOVE(ngl, node);