From eb1bde0da148181c145d74dc44d9bc450304553c Mon Sep 17 00:00:00 2001 From: Gilbok Lee Date: Tue, 23 Jan 2024 09:36:44 +0900 Subject: [PATCH] [0.6.290] Fix coverity issue (MISSING_LOCK) Change-Id: Ibec8c461cb58ceedfff50a184ed108bb8b484568 --- src/mm_player_gst.c | 2 ++ src/mm_player_priv.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/mm_player_gst.c b/src/mm_player_gst.c index 0c57672..5ba2047 100644 --- a/src/mm_player_gst.c +++ b/src/mm_player_gst.c @@ -916,10 +916,12 @@ __mmplayer_gst_check_useful_message(mmplayer_t *player, GstMessage *message) case GST_MESSAGE_ASYNC_DONE: case GST_MESSAGE_STATE_CHANGED: /* we only handle messages from pipeline */ + MMPLAYER_RECONFIGURE_LOCK(player); if ((message->src == (GstObject *)player->pipeline->mainbin[MMPLAYER_M_PIPE].gst) && (!player->gapless.reconfigure)) retval = TRUE; else retval = FALSE; + MMPLAYER_RECONFIGURE_UNLOCK(player); break; case GST_MESSAGE_BUFFERING: { diff --git a/src/mm_player_priv.c b/src/mm_player_priv.c index d8d1141..855943e 100644 --- a/src/mm_player_priv.c +++ b/src/mm_player_priv.c @@ -1040,10 +1040,12 @@ __mmplayer_gst_combiner_event_probe(GstPad *pad, GstPadProbeInfo *info, gpointer case GST_EVENT_EOS: { /* in case of gapless, drop eos event not to send it to sink */ + MMPLAYER_RECONFIGURE_LOCK(player); if (player->gapless.reconfigure && !player->msg_posted) { LOGD("[%d] %s:%s EOS received but will be drop", stream_type, GST_DEBUG_PAD_NAME(pad)); ret = GST_PAD_PROBE_DROP; } + MMPLAYER_RECONFIGURE_UNLOCK(player); break; } case GST_EVENT_STREAM_START: -- 2.34.1