nwfilter: Add missing driver lock in qemu driver

This adds a missing driver lock in the qemu driver to protect
the list of domains.
This commit is contained in:
Stefan Berger 2010-05-14 14:22:39 -04:00
parent d6644013d2
commit ba99a1b637

View File

@ -11874,11 +11874,15 @@ static virStateDriver qemuStateDriver = {
};
static int
qemudVMFilterRebuild(virConnectPtr conn,
qemudVMFilterRebuild(virConnectPtr conn ATTRIBUTE_UNUSED,
virHashIterator iter, void *data)
{
(void)conn;
struct qemud_driver *driver = qemu_driver;
qemuDriverLock(driver);
virHashForEach(qemu_driver->domains.objs, iter, data);
qemuDriverUnlock(driver);
return 0;
}