[PD-dev] To free inlets and outlets or not to free in-/out-lets?

Fred Jan Kraan fjkraan at xs4all.nl
Fri Nov 4 15:43:24 CET 2016


Hi Devs,

According to the Externals-HOWTO it is required to free the created 
inlets and outlets. This makes sense as Pd allocates memory for them and 
frees it on calling inlet_free() and outlet_free(). But the practice is 
not very common, and the (recent) pd_free also attempts to free them. It 
does this after checking there is a *_free() method and calling it.

Is there a good reason to free the in- and out-lets from the object 
*_free() method anyhow? After all, it is extra code, that could contain 
errors too?

Greetings,

Fred Jan



More information about the Pd-dev mailing list