[vlc-devel] [PATCH] MediaCodec: simplify jni thread attach/detach
Zhang Rui
bbcallen at gmail.com
Wed Feb 26 05:47:32 CET 2014
Thanks for the review.
Sorry about mis-send last unfinished reply.
2014-02-25 23:49 GMT+08:00 Rémi Denis-Courmont <remi at remlab.net>:
> On Tue, 25 Feb 2014 17:02:13 +0800, Zhang Rui <bbcallen at gmail.com> wrote:
>
>> +{
>> + pthread_key_create(&g_thread_key, vlcjni_thread_destroy);
>> +}
>
> This may be theoretical so far. But technically that is a leak and a
> potentially dangling clean-up handler callback.
May I have your suggestion here?
Since decode thread is not owned by MediaCodec module,
MediaCodec has no chance to do explicit clean-up, except
1. repeatly Attach/Detach in the old way.
2. create private thread to do jvm stuff.
More information about the vlc-devel
mailing list