[Bug 797251] webrtcbin: might leak resources when changing to NULL

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Fri Oct 5 18:03:34 UTC 2018


https://bugzilla.gnome.org/show_bug.cgi?id=797251

--- Comment #10 from Aleix Conchillo FlaquƩ <aconchillo at gmail.com> ---
Without any patch, these are some of the threads that freeze. I believe the
problem  with all of them (as I mentioned in comment 8) is that webrtcbin is
trying to be disposed from inside _execute_op.

Thread 9 (Thread 0x7fd14bfff700 (LWP 25845)):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fd17028a0ac in g_mutex_lock_slowpath (mutex=0x7fd14006eea0) at
gthread-posix.c:1320
#2  0x00007fd17028ad52 in g_mutex_lock (mutex=<optimized out>) at
gthread-posix.c:1344
#3  0x00007fd15c4b88d4 in _stop_thread (webrtc=0x7fd14006ef00) at
gstwebrtcbin.c:614
#4  gst_webrtc_bin_dispose (object=0x7fd14006ef00) at gstwebrtcbin.c:3961
#5  0x00007fd170527855 in g_object_unref (_object=0x7fd14006ef00) at
gobject.c:3309
#6  0x00007fd17054e0a0 in g_value_unset (value=0x7fd14bffe700) at gvalue.c:275
#7  0x00007fd17052b215 in g_object_new_valist (object_type=<optimized out>,
first_property_name=first_property_name at entry=0x7fd15c4c6dd6 "webrtc",
var_args=var_args at entry=0x7fd14bffe900) at gobject.c:2131
#8  0x00007fd17052b6e9 in g_object_new (object_type=<optimized out>,
first_property_name=first_property_name at entry=0x7fd15c4c6dd6 "webrtc") at
gobject.c:1648
#9  0x00007fd15c4c3627 in transport_stream_new
(webrtc=webrtc at entry=0x7fd14006ef00, session_id=session_id at entry=0) at
transportstream.c:248
#10 0x00007fd15c4b7b53 in _create_transport_channel
(webrtc=webrtc at entry=0x7fd14006ef00, session_id=session_id at entry=0) at
gstwebrtcbin.c:1367
#11 0x00007fd15c4bbe3c in sdp_media_from_transceiver
(type=GST_WEBRTC_SDP_TYPE_OFFER, media_idx=0, trans=0x7fd0d00196a0,
media=0x7fd14bffeab0, webrtc=0x7fd14006ef00) at gstwebrtcbin.c:1742
#12 _create_offer_task (options=<optimized out>, webrtc=0x7fd14006ef00) at
gstwebrtcbin.c:1811
#13 _create_sdp_task (webrtc=0x7fd14006ef00, data=0x7fd0d0003970) at
gstwebrtcbin.c:2205
#14 0x00007fd15c4b6a2a in _execute_op (op=0x7fd0d0043340) at gstwebrtcbin.c:634
#15 0x00007fd1702348ba in g_main_dispatch (context=0x7fd0d0044000) at
gmain.c:3182
#16 g_main_context_dispatch (context=context at entry=0x7fd0d0044000) at
gmain.c:3847
#17 0x00007fd170234d18 in g_main_context_iterate (context=0x7fd0d0044000,
block=block at entry=1, dispatch=dispatch at entry=1, self=<optimized out>) at
gmain.c:3920
#18 0x00007fd170235252 in g_main_loop_run (loop=0x7fd0d00457a0) at gmain.c:4116
#19 0x00007fd15c4b6b7a in _gst_pc_thread (webrtc=0x7fd14006ef00) at
gstwebrtcbin.c:585
#20 0x00007fd170267ac5 in g_thread_proxy (data=0x7fd1400815e0) at gthread.c:784
#21 0x00007fd1711bd6ba in start_thread (arg=0x7fd14bfff700) at
pthread_create.c:333
#22 0x00007fd16de5341d in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:109

This one is the same as comment 8 and the one that leaks a bunch of sockets:

Thread 9 (Thread 0x7f8f2b7fe700 (LWP 28229)):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007f8f4377deaf in g_cond_wait (cond=0x7f8f1803e1a8,
mutex=0x7f8f1803e1a0) at gthread-posix.c:1402
#2  0x00007f8f311e590d in _stop_thread (webrtc=0x7f8f1803e200) at
gstwebrtcbin.c:618
#3  gst_webrtc_bin_dispose (object=0x7f8f1803e200) at gstwebrtcbin.c:3961
#4  0x00007f8f43a1a855 in g_object_unref (_object=0x7f8f1803e200) at
gobject.c:3309
#5  0x00007f8f43a410a0 in g_value_unset (value=value at entry=0x7f8f2b7fd870) at
gvalue.c:275
#6  0x00007f8f43a3311b in g_signal_emit_valist (instance=<optimized out>,
signal_id=<optimized out>, detail=<optimized out>,
var_args=var_args at entry=0x7f8f2b7fda50) at gsignal.c:3421
#7  0x00007f8f43a334af in g_signal_emit
(instance=instance at entry=0x7f8f1803e200, signal_id=<optimized out>,
detail=detail at entry=0) at gsignal.c:3447
#8  0x00007f8f311e3981 in _on_ice_candidate_task (webrtc=0x7f8f1803e200,
item=0x7f8ee0105840) at gstwebrtcbin.c:3162
#9  0x00007f8f311e3a2a in _execute_op (op=0x7f8ee01098a0) at gstwebrtcbin.c:634
#10 0x00007f8f437278ba in g_main_dispatch (context=0x7f8ee0115a00) at
gmain.c:3182
#11 g_main_context_dispatch (context=context at entry=0x7f8ee0115a00) at
gmain.c:3847
#12 0x00007f8f43727d18 in g_main_context_iterate (context=0x7f8ee0115a00,
block=block at entry=1, dispatch=dispatch at entry=1, self=<optimized out>) at
gmain.c:3920
#13 0x00007f8f43728252 in g_main_loop_run (loop=0x7f8ee007dd60) at gmain.c:4116
#14 0x00007f8f311e3b7a in _gst_pc_thread (webrtc=0x7f8f1803e200) at
gstwebrtcbin.c:585
#15 0x00007f8f4375aac5 in g_thread_proxy (data=0x7f8eec0ab990) at gthread.c:784
#16 0x00007f8f446b06ba in start_thread (arg=0x7f8f2b7fe700) at
pthread_create.c:333
#17 0x00007f8f4134641d in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:109

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list