[x264-devel] libx264 memory leak

Alexander Strange astrange at ithinksw.com
Wed Mar 4 05:58:52 CET 2009


On Mar 3, 2009, at 4:28 PM, Loren Merritt wrote:

> On Tue, 3 Mar 2009, Leon Woestenberg wrote:
>>
>> Under Unices, using a library constructor/destructor approach is  
>> available:
>>
>> http://www.faqs.org/docs/Linux-HOWTO/Program-Library-HOWTO.html#INIT-AND-CLEANUP
>>
>> Not sure how Windows handles that though,
>
> No way am I using a OS-specific feature for this. If shutting up  
> valgrind is really important, just put it in a static array.
>
> --Loren Merritt

It's a gcc-ism, but it works on every gcc platform (unless there are  
platforms that don't support C++?).

So you'd still need an #ifdef to check the compiler, which you might  
not like any better.



More information about the x264-devel mailing list