summary refs log tree commit diff stats
path: root/hw/avr/arduino.c
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2021-02-19 16:33:46 +0100
committerKevin Wolf <kwolf@redhat.com>2021-03-08 14:55:18 +0100
commitbdc4c4c5e372756a5ba3fb3a61e585b02f0dd7f4 (patch)
tree0356be06723ca9717e392ff999c3b303c458fbe7 /hw/avr/arduino.c
parentfa818b2febfc090acb9b2e69c1c2a4e4b38aee83 (diff)
downloadfocaccia-qemu-bdc4c4c5e372756a5ba3fb3a61e585b02f0dd7f4.tar.gz
focaccia-qemu-bdc4c4c5e372756a5ba3fb3a61e585b02f0dd7f4.zip
backup: Remove nodes from job in .clean()
The block job holds a reference to the backup-top node (because it is
passed as the main job BDS to block_job_create()).  Therefore,
bdrv_backup_top_drop() cannot delete the backup-top node (replacing it
by its child does not affect the job parent, because that has
.stay_at_node set).  That is a problem, because all of its I/O functions
assume the BlockCopyState (s->bcs) to be valid and that it has a
filtered child; but after bdrv_backup_top_drop(), neither of those
things are true.

It does not make sense to add new parents to backup-top after
backup_clean(), so we should detach it from the job before
bdrv_backup_top_drop().  Because there is no function to do that for a
single node, just detach all of the job's nodes -- the job does not do
anything past backup_clean() anyway.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Message-Id: <20210219153348.41861-2-mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'hw/avr/arduino.c')
0 files changed, 0 insertions, 0 deletions