[Libav-user] multithreaded problems

Michael Chisholm chisholm at mitre.org
Wed Nov 9 21:14:19 CET 2011


Afaik, you should call av_lockmgr_register() to set a locking handler, 
if you're calling ffmpeg APIs from multiple threads simultaneously.

Andy

On 11/9/2011 1:06 PM, Karoly Horvath wrote:
> Hi guys,
>
> I have multiple threads which do simultaneous demultiplexing for different
> streams.
>
> Most of the times it works fine, but sometimes a see these messages at
> startup:
> [NULL @ 0x7fffa4006120] insufficient thread locking around
> avcodec_open/close()
> Also it sometimes fails to do avcodec_open (it's the same stream, nothing
> changed..)
>
> I have a global mutex for the threads so at any point only one thread can
> make those API calls.
>
> Any idea what the problem is?
>
> thx
>
>
>
>
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/libav-user



More information about the Libav-user mailing list