On 16.06.2015 19:43, Peter Krempa wrote: > Retrieve domain objects with reference and release them with > virDomainObjEndAPI. > --- > src/test/test_driver.c | 89 ++++++++++++++++++++------------------------------ > 1 file changed, 35 insertions(+), 54 deletions(-) > > diff --git a/src/test/test_driver.c b/src/test/test_driver.c > index c0ef459..6613ed7 100644 > --- a/src/test/test_driver.c > +++ b/src/test/test_driver.c > @@ -484,7 +484,7 @@ testDomObjFromDomain(virDomainPtr domain) > char uuidstr[VIR_UUID_STRING_BUFLEN]; > > testDriverLock(driver); > - vm = virDomainObjListFindByUUID(driver->domains, domain->uuid); > + vm = virDomainObjListFindByUUIDRef(driver->domains, domain->uuid); > if (!vm) { > virUUIDFormat(domain->uuid, uuidstr); > virReportError(VIR_ERR_NO_DOMAIN, Oh, this reminds me that I wanted to drop testDriverLock. It's unnecessary here - domainObjList has self-locking APIs. ACK Michal -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list