Commit 4e943d01 authored by Thomas Guillem's avatar Thomas Guillem Committed by Jean-Baptiste Kempf

android/opaque: check if subtitles_picture is not NULL

Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent fb23e240
...@@ -265,7 +265,8 @@ static void Close(vlc_object_t *p_this) ...@@ -265,7 +265,8 @@ static void Close(vlc_object_t *p_this)
if (sys->window) if (sys->window)
sys->native_window.winRelease(sys->window); sys->native_window.winRelease(sys->window);
dlclose(sys->p_library); dlclose(sys->p_library);
picture_Release(sys->subtitles_picture); if (sys->subtitles_picture)
picture_Release(sys->subtitles_picture);
if (sys->p_spu_blend) if (sys->p_spu_blend)
filter_DeleteBlend(sys->p_spu_blend); filter_DeleteBlend(sys->p_spu_blend);
free(sys); free(sys);
...@@ -304,7 +305,7 @@ static void Display(vout_display_t *vd, picture_t *picture, subpicture_t *subpic ...@@ -304,7 +305,7 @@ static void Display(vout_display_t *vd, picture_t *picture, subpicture_t *subpic
if (display_callback) if (display_callback)
display_callback(p_picsys); display_callback(p_picsys);
if (subpicture) if (subpicture && sys->subtitles_picture)
sys->b_has_subpictures = true; sys->b_has_subpictures = true;
/* As long as no subpicture was received, do not call /* As long as no subpicture was received, do not call
DisplaySubpicture since JNI calls and clearing the subtitles DisplaySubpicture since JNI calls and clearing the subtitles
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment