[Kdenlive-devel] strange behaviour in mlt reaching eof

Ed Rogalsky ed.rogalsky at gmail.com
Sat Dec 15 18:11:32 UTC 2012


Hi Dan,

I found out that the
commit e33dedb46c0e4786023e1fe0a618e3f4a35728ae (Improve stop handling in
mlt_consumer)
has a side effect to eof behaviour (see ticket
http://www.kdenlive.org/mantis/view.php?id=2870).

I can reproduce the hanging on reaching eof in mlt. The crazy sound is only
reproducable in kdenlive.

steps to reproduce:

bash# MLT_CONSUMER=sdl_preview melt movie.mov => on reaching eof --->
hanging and melt has to be killed

I guess there is a deadlock or so.

mlt_consumer.c:

/** Stop the consumer.
 *
 * \public \memberof mlt_consumer_s
 * \param self a consumer
 * \return true if there was an error
 */

int mlt_consumer_stop( mlt_consumer self )
{
// Return error if supplied invalid or stopped consumer.
if ( !self /*|| mlt_consumer_is_stopped( self )*/ ) <= Look at commment
return -1;

I commented the check mlt_consumer_is_stopped( self ) => works again.

I think there are conditions where the consumer says I'm "stopped" but
forcing/calling the  mlt_consumer_stop function is
needed in some circumstances for example pthread_cond_broadcasting or what
ever. I think you know it better!

Sorry I don't have to much time now for deeper investigation. I hope my
hints are enough for a solution.

regards

eddrog
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdenlive/attachments/20121215/f7af129d/attachment.html>


More information about the Kdenlive mailing list