aboutsummaryrefslogtreecommitdiff
path: root/migration-fd.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2013-03-27 17:28:18 +0100
committerStefan Hajnoczi <stefanha@redhat.com>2013-03-28 11:58:40 +0100
commit5d186eb03eb37b257e29a4731ca484362d5fc4e4 (patch)
treeffa427b0c9df054073f6b9fb17b016697a9339dc /migration-fd.c
parentecdd5333ab9ed3f2b848066aaaef02c027b25e36 (diff)
block: Fix direct use of protocols as driver for bdrv_open()
bdrv_open_common() implements direct use of protocols by copying the pre-opened BlockDriverStates to bs using bdrv_swap(). It did however first set some fields in bs, which end up in file after the swap. When bdrv_open() destroys file, it appears to be open, and because it isn't, qemu could segfault while trying to close it. Reorder the operations to return immediately in such cases so that file is correctly detected as closed. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'migration-fd.c')
0 files changed, 0 insertions, 0 deletions