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

Re: [libvirt] [PATCH v2 2/2] Use virCheckFlags for APIs added in 0.8.0



> I scanned through the patch, and didn't see any instances where we are
> calling virCheckFlags after non-trivial work.  It is something to be
> aware of when using the macro in the future, since:
> 
> {
>     ptr *foo = somethingThatMallocs();
>     virCheckFlags(0, NULL);
> 
> would be a memory leak, masked because the return is hidden inside the
> virCheckFlags macro.

Yes. I added a note to macro documentation to make this issue more visible.

> ACK.

And pushed, thanks.

Jirka


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