[FFmpeg-devel] ffplay is missing avcodec_thread_free()

Benoit Fouet benoit.fouet
Fri Jul 6 17:12:02 CEST 2007


Michael Niedermayer wrote:
> Hi
>
> On Fri, Jul 06, 2007 at 04:01:17PM +0200, Andreas ?man wrote:
>   
>> Hi
>>
>> Benoit Fouet wrote:
>>     
>>> Hi,
>>>
>>> Janne Grunau wrote:
>>>       
>>>> On Thursday 28 June 2007 18:57:54 Michael Niedermayer wrote:
>>>>   
>>>>         
>>>>> Hi
>>>>>
>>>>> why not put the avcodec_thread_free() call in avcodec_close() ?
>>>>>     
>>>>>           
>>>> as attached patch?
>>>>
>>>>         
>>> i don't think ENABLE_THREADS is useful
>>>
>>>       
>> More importantly, if an application already calls avcodec_thread_free()
>> this patch will (most likely) crash the application,
>> as pointed out by Thorsten in a previous mail in this thread.
>>     
>
> then set thread_opaque to NULL in avcodec_thread_free()
>
> [...]
>
>   

is the attached patch ok for that ?
(i looked into *thread.c and this is the only file not using av_freep())

-- 
Ben
Purple Labs S.A.
www.purplelabs.com
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pthread.c.diff
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070706/385ad153/attachment.asc>



More information about the ffmpeg-devel mailing list