appsink python memory leak?? unref call on sample? FIXED??

Tim Müller tim at centricular.com
Sun Apr 17 19:55:54 UTC 2016


On Sun, 2016-04-17 at 19:40 +0000, Turmel, Frederic wrote:

Hi,

> I think I figured out what is going on. Using GST_TRACE=mem-live was
> an eye opener. Using the debug flag showed that there was several
> thousand GST_Message variable allocated along with tsdemux type
> variable.
> 
> ****So it turns out that any message not received/read in python are
> accumulating forever. That is, even if you don't ask for it.  TSdemux
> seems to be very chatty on the bus with the source I'm using. I'm
> getting several messages per seconds once I listen to the bus. These
> were eating memory.
> 
> Is this the correct behavior or that is a bug? Not sure if that is
> intended? 

That is expected behaviour. Your application must handle bus messages
in some form. You can set the pipeline bus to flushing if you have a
use case where you really want to ignore them, but really any
application that's more than 5 lines of code needs to handle bus
messages.

 Cheers
  -Tim

-- 
Tim Müller, Centricular Ltd - http://www.centricular.com




More information about the gstreamer-devel mailing list