[vlc-devel] [PATCH 00/12] Make clean-up functions behave like free

Rémi Denis-Courmont remi at remlab.net
Mon Mar 14 18:27:48 CET 2016


Le 2016-03-14 12:08, Filip Roséen a écrit :
> The patches in this patch-batch allows for (the affected) clean-up
> functions to
> safely be called with a pointer-to-NULL, effectivelly removing 
> one-statement
> if-branches to conditionally invoke such function.

For pure memory objects, it's debatable whether NULL should be allowed. 
But for more complex ones, please do not do this. This had lead to a lot 
of sloppy and buggy code in the past. Nack.
-- 
Rémi Denis-Courmont
http://www.remlab.net/


More information about the vlc-devel mailing list