From: Eunhye Choi Date: Wed, 24 Aug 2022 10:02:09 +0000 (+0900) Subject: [0.6.271] set the textbin clock to the referenced pipeline clock X-Git-Tag: accepted/tizen/7.0/unified/hotfix/20221116.105424^0 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fmultimedia%2Flibmm-player.git;a=commitdiff_plain;h=b20e821f40435db7a9491d58e963931b38b24b0b [0.6.271] set the textbin clock to the referenced pipeline clock - fix crash issue - pipeline clock is released when the subtitle pipeline state is sync to main pipeline during playing which cause crash when the main pipeline is unreferenced. Change-Id: Id71adee2288b41bb5ce5202a7f05a41917aa9374 --- diff --git a/packaging/libmm-player.spec b/packaging/libmm-player.spec index 778e5a6..5a1b4e2 100644 --- a/packaging/libmm-player.spec +++ b/packaging/libmm-player.spec @@ -1,6 +1,6 @@ Name: libmm-player Summary: Multimedia Framework Player Library -Version: 0.6.270 +Version: 0.6.271 Release: 0 Group: Multimedia/Libraries License: Apache-2.0 diff --git a/src/mm_player_priv.c b/src/mm_player_priv.c index eb5ad2a..bcf15b5 100644 --- a/src/mm_player_priv.c +++ b/src/mm_player_priv.c @@ -8252,7 +8252,7 @@ _mmplayer_sync_subtitle_pipeline(mmplayer_t *player) current_state = GST_STATE(mainbin[MMPLAYER_M_PIPE].gst); // sync clock with current pipeline - curr_clock = GST_ELEMENT_CLOCK(player->pipeline->mainbin[MMPLAYER_M_PIPE].gst); + curr_clock = gst_element_get_clock(player->pipeline->mainbin[MMPLAYER_M_PIPE].gst); curr_time = gst_clock_get_time(curr_clock); base_time = gst_element_get_base_time(GST_ELEMENT_CAST(player->pipeline->mainbin[MMPLAYER_M_PIPE].gst)); @@ -8271,6 +8271,8 @@ _mmplayer_sync_subtitle_pipeline(mmplayer_t *player) if (GST_STATE_CHANGE_FAILURE == ret) { LOGE("fail to state change."); result = MM_ERROR_PLAYER_INTERNAL; + if (curr_clock) + gst_object_unref(curr_clock); goto ERROR; } }