Question on usage of gst_deinit(), freeing of all allocated memory objects?

Sebastian Dröge sebastian at centricular.com
Fri Apr 21 10:49:16 UTC 2017


On Fri, 2017-04-21 at 07:20 +0200, Martin Maurer wrote:
> Hi,
> 
> I have a question regarding gst_deinit().
> 
> In the docs
> 
> https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-Gst.html#gst-deinit
> 
> it is mentioned
> 
> "This function is therefore mostly used by testsuites and other memory 
> profiling tools.
> 
> After this call GStreamer (including this method) should not be used 
> anymore."
> 
> Does gst_deinit() clean all previously allocated resources? So I get 
> back a clean environment?

It deallocates all one-time allocations done by GStreamer (but there
are more done by GLib and other libraries). And it does not deallocate
anything that was previously leaked due to bugs.

> When GStreamer it not allowed anymore after gst_deinit(), is it allowed 
> or forbidden to start a new "session" with gst_init()? How do testsuites 
> and memory profiling tools handle the case that previous testcase/action 
> could have messed around especially regarding memory allocation?

You can't run gst_init() after gst_deinit() anymore. The tests are
running each test in its own process.

-- 
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1000 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20170421/2ddded3c/attachment.sig>


More information about the gstreamer-devel mailing list