webrtc_private: Add defensive code regarding destroying handle 90/319590/1
authorSangchul Lee <sc11.lee@samsung.com>
Mon, 28 Oct 2024 03:53:06 +0000 (12:53 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Mon, 28 Oct 2024 03:53:22 +0000 (12:53 +0900)
[Version] 0.4.71
[Issue Type] ASAN defect

Change-Id: Iaf57f54224e91b18c40ba1055c6e5c7cb35b7536
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
packaging/capi-media-webrtc.spec
src/webrtc_private.c

index 9394ed7ec7588288901af8497634a13ae10701e8..46b3653a6ba2fa63414c8fed0d3153768347e1b1 100644 (file)
@@ -1,6 +1,6 @@
 Name:       capi-media-webrtc
 Summary:    A WebRTC library in Tizen Native API
-Version:    0.4.70
+Version:    0.4.71
 Release:    0
 Group:      Multimedia/API
 License:    Apache-2.0
index c5806c2cded46ab572719a87af963c679177a8ea..e8ca08f0769f5433010aa4c97e75a40bfb6ab819 100644 (file)
@@ -641,6 +641,10 @@ static gboolean __idle_cb(gpointer user_data)
        }
 
        webrtc = data->webrtc;
+       if (webrtc->is_destroying) {
+               LOG_WARNING("webrtc is destroying, skip it");
+               return G_SOURCE_REMOVE;
+       }
 
        switch (data->type) {
        case IDLE_CB_TYPE_STATE: {