diff options
author | Laine Stump <laine@laine.org> | 2013-05-31 14:30:09 -0400 |
---|---|---|
committer | Laine Stump <laine@laine.org> | 2013-05-31 15:00:10 -0400 |
commit | 749d1fd321e71877f445887748f919a7e9c33d58 (patch) | |
tree | 23a968d6d84013ba6247a3bb912727ca2fd4e81c | |
parent | 7d5e3f026603d7e6d78254e972332fdd6b234863 (diff) | |
download | libvirt-749d1fd321e71877f445887748f919a7e9c33d58.tar.gz |
qemu: prevent termination of guests w/hostdev on driver reconnect
This should resolve:
https://bugzilla.redhat.com/show_bug.cgi?id=959191
The problem was that qemuUpdateActivePciHostdevs was returning 0
(success) when no hostdevs were present, but would otherwise return -1
(failure) even when it completed successfully. It is only called from
qemuProcessReconnect(), and when qemuProcessReconnect got back an
error, it would not only stop reconnecting, but would terminate the
guest qemu process "to remove danger of it ending up running twice if
user tries to start it again later".
(This bug was introduced in commit 011cf7ad, which was pushed between
v1.0.2 and v1.0.3, so all maintenance branches from v1.0.3 up to 1.0.5
will need this one line patch applied.)
(cherry picked from commit 2ea45647bcde23cff5da48f725561ff5ba3fba39)
-rw-r--r-- | src/qemu/qemu_hostdev.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/qemu/qemu_hostdev.c b/src/qemu/qemu_hostdev.c index bac38b5672..9a39a4afa5 100644 --- a/src/qemu/qemu_hostdev.c +++ b/src/qemu/qemu_hostdev.c @@ -163,6 +163,7 @@ int qemuUpdateActivePciHostdevs(virQEMUDriverPtr driver, } } + ret = 0; cleanup: virObjectUnlock(driver->activePciHostdevs); virObjectUnlock(driver->inactivePciHostdevs); |