qemu-e2k/hw/core
Marc-André Lureau 265b578c58 object: fix OBJ_PROP_LINK_UNREF_ON_RELEASE ambivalence
A link property can be set during creation, with
object_property_add_link() and later with object_property_set_link().

add_link() doesn't add a reference to the target object, while
set_link() does.

Furthemore, OBJ_PROP_LINK_UNREF_ON_RELEASE flags, set during add_link,
says whether a reference must be released when the property is destroyed.
This can lead to leaks if the property was later set_link(), as the
added reference is never released.

Instead, rename OBJ_PROP_LINK_UNREF_ON_RELEASE to OBJ_PROP_LINK_STRONG
and use that has an indication on how the link handle reference
management in set_link().

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-id: 20180531195119.22021-3-marcandre.lureau@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-06-12 12:07:30 +02:00
..
bus.c bus: do not unref the added child bus on realize 2018-06-12 12:07:29 +02:00
empty_slot.c
fw-path-provider.c
generic-loader.c hw/core/generic-loader: Allow PC to be set on command line 2018-02-09 10:55:40 +00:00
hotplug.c
irq.c
loader-fit.c hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
loader.c Add symbol table callback interface to load_elf 2018-03-07 08:30:28 +13:00
machine.c numa: postpone options post-processing till machine_run_board_init() 2018-05-30 13:08:11 -03:00
Makefile.objs hw/core/split-irq: Device that splits IRQ lines 2018-03-02 11:03:45 +00:00
nmi.c
null-machine.c Use cpu_create(type) instead of cpu_init(cpu_model) 2018-03-19 14:10:36 -03:00
or-irq.c qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable 2017-05-17 10:37:00 -03:00
platform-bus.c hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
ptimer.c
qdev-fw.c linux-user: remove nmi.c and fw-path-provider.c 2018-01-23 14:20:52 +01:00
qdev-properties-system.c net: Remove the deprecated "vlan" parameter 2018-05-14 15:47:14 +08:00
qdev-properties.c object: fix OBJ_PROP_LINK_UNREF_ON_RELEASE ambivalence 2018-06-12 12:07:30 +02:00
qdev.c object: fix OBJ_PROP_LINK_UNREF_ON_RELEASE ambivalence 2018-06-12 12:07:30 +02:00
register.c hw/core/register: Add trailing '\n' to qemu_log() call 2018-06-08 13:15:33 +01:00
reset.c
split-irq.c hw/core/split-irq: Device that splits IRQ lines 2018-03-02 11:03:45 +00:00
stream.c
sysbus.c qdev: Simplify the SysBusDeviceClass::init path 2018-06-01 15:14:31 +02:00
uboot_image.h