[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] PATCH: Reset global error object at end of test



"Daniel P. Berrange" <berrange redhat com> wrote:
> There statstest test case is expected to raise a number of libvirt
> errors. Since these are now stored in thread locals, it is expected
> that this won't be free'd automatically at system shutdown. This
> patch adds a call to virResetError() at the end to release the memory
> associated with the stored error object. There is still one block of
> memory alocated though, which is the thread local error error object
> itself. We can't free this easily, so I just add a valgrind suppression
> rule instead. This lets 'make valgrind' pass again
>
> Also since the test case doesn't call virInitialize()as a normal
> app would do, we need to explicitly initialize the thread local storage
> to ensure things work correctly.

valgrind++
ACK.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]