diff --git a/sys/androidmedia/gstamcvideodec.c b/sys/androidmedia/gstamcvideodec.c index 8cd1838a05..1d4e2282be 100644 --- a/sys/androidmedia/gstamcvideodec.c +++ b/sys/androidmedia/gstamcvideodec.c @@ -553,6 +553,9 @@ _find_nearest_frame (GstAmcVideoDec * self, GstClockTime reference_timestamp) } } + if (best) + gst_video_codec_frame_ref (best); + g_list_foreach (frames, (GFunc) gst_video_codec_frame_unref, NULL); g_list_free (frames);