<div dir="ltr"><div><div><div>Hello again,<br></div>I have run valgrind again with debug symbol and this is the output for libnice <b>v0.1.10</b>:<br><br><b>nice_agent_gather_candidates</b><br>==12303== 688 (80 direct, 608 indirect) bytes in 2 blocks are definitely lost in loss record 8,233 of 8,519<br>==12303==    at 0x517247A: g_type_create_instance (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x51571EC: g_object_new_internal (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x51590B3: g_object_new_valist (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x79515F8: g_initable_new_valist (in /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0.4200.1)<br>==12303==    by 0x79516EB: g_initable_new (in /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0.4200.1)<br>==12303==    by 0x7968BA7: g_socket_new (in /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0.4200.1)<br>==12303==    by 0xA6B3578: nice_tcp_passive_socket_new (tcp-passive.c:96)<br>==12303==    by 0xA6A8E1E: discovery_add_local_host_candidate (discovery.c:563)<br>==12303==    by 0xA69F7C2: nice_agent_gather_candidates (agent.c:2737)<br>==12303==    by 0xA28249F: kms_webrtc_endpoint_gather_candidates (kmswebrtcendpoint.c:764)<br>==12303==    by 0xA2843DC: __kms_webrtc_marshal_BOOLEAN__VOID (kms-webrtc-marshal.c:83)<br>==12303==    by 0x51521C7: g_closure_invoke (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516318A: signal_emit_unlocked_R (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516AD67: g_signal_emit_valist (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516B881: g_signal_emit_by_name (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x402D9E: test_audio_sendrecv.constprop.4 (webrtcendpoint.c:700)<br>==12303==    by 0x4030B6: test_pcmu_sendrecv (webrtcendpoint.c:1253)<br>==12303==    by 0x56ABE79: srunner_run_all (in /usr/lib/x86_64-linux-gnu/libgstcheck-1.0.so.0.404.0)<br>==12303==    by 0x56A5BFD: gst_check_run_suite (in /usr/lib/x86_64-linux-gnu/libgstcheck-1.0.so.0.404.0)<br>==12303==    by 0x401E63: main (webrtcendpoint.c:1305)<br><br>==12303== 528 (208 direct, 320 indirect) bytes in 2 blocks are definitely lost in loss record 8,131 of 8,519<br>==12303==    at 0x4C2AB80: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)<br>==12303==    by 0x53E13D0: g_malloc (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4200.1)<br>==12303==    by 0x53F70ED: g_slice_alloc (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4200.1)<br>==12303==    by 0x53F762D: g_slice_alloc0 (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4200.1)<br>==12303==    by 0xA6B26F1: nice_tcp_active_socket_new (tcp-active.c:106)<br>==12303==    by 0xA6A8DFE: discovery_add_local_host_candidate (discovery.c:561)<br>==12303==    by 0xA69F7C2: nice_agent_gather_candidates (agent.c:2737)<br>==12303==    by 0xA28249F: kms_webrtc_endpoint_gather_candidates (kmswebrtcendpoint.c:764)<br>==12303==    by 0xA2843DC: __kms_webrtc_marshal_BOOLEAN__VOID (kms-webrtc-marshal.c:83)<br>==12303==    by 0x51521C7: g_closure_invoke (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516318A: signal_emit_unlocked_R (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516AD67: g_signal_emit_valist (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516B881: g_signal_emit_by_name (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x402D9E: test_audio_sendrecv.constprop.4 (webrtcendpoint.c:700)<br>==12303==    by 0x4030B6: test_pcmu_sendrecv (webrtcendpoint.c:1253)<br>==12303==    by 0x56ABE79: srunner_run_all (in /usr/lib/x86_64-linux-gnu/libgstcheck-1.0.so.0.404.0)<br>==12303==    by 0x56A5BFD: gst_check_run_suite (in /usr/lib/x86_64-linux-gnu/libgstcheck-1.0.so.0.404.0)<br>==12303==    by 0x401E63: main (webrtcendpoint.c:1305)<br><br><br><b>nice_agent_add_stream</b><br>==12303== 144 bytes in 2 blocks are possibly lost in loss record 7,624 of 8,519<br>==12303==    at 0x4C2CC70: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)<br>==12303==    by 0x53E1428: g_malloc0 (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4200.1)<br>==12303==    by 0x5151104: g_closure_new_simple (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x51525A1: g_cclosure_new (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x516909E: g_signal_connect_data (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br>==12303==    by 0x792F40B: g_cancellable_source_new (in /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0.4200.1)<br>==12303==    by 0xA697CB1: component_new (component.c:150)<br>==12303==    by 0xA6A1EDF: stream_new (stream.c:68)<br>==12303==    by 0xA69B49F: nice_agent_add_stream (agent.c:2361)<br>==12303==    by 0xA27F6B5: kms_webrtc_base_connection_configure (kmswebrtcbaseconnection.c:35)<br>==12303==    by 0xA2811A4: kms_webrtc_bundle_connection_new (kmswebrtcbundleconnection.c:211)<br>==12303==    by 0xA282B95: kms_webrtc_endpoint_create_bundle_connection (kmswebrtcendpoint.c:172)<br>==12303==    by 0x58C22F0: kms_base_rtp_endpoint_configure_media (kmsbasertpendpoint.c:487)<br>==12303==    by 0xA282D28: kms_webrtc_endpoint_configure_media (kmswebrtcendpoint.c:541)<br>==12303==    by 0x6E558FA: create_media_answer (kmssdpagent.c:487)<br>==12303==    by 0x58CE6B2: sdp_utils_for_each_media (sdp_utils.c:811)<br>==12303==    by 0x6E5562F: kms_sdp_agent_create_answer_impl (kmssdpagent.c:524)<br>==12303==    by 0x58C542D: kms_base_sdp_endpoint_process_offer (kmsbasesdpendpoint.c:377)<br>==12303==    by 0x58CB614: __kms_core_marshal_BOXED__BOXED (kms-core-marshal.c:121)<br>==12303==    by 0x51521C7: g_closure_invoke (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.4200.1)<br><br><br>I cannot reproduce the memory leak that I reported some days ago about <b>g_source_set_dummy_callback</b>. But I have searched for it into libnice code, and I have found this entries:<br>agent/outputstream.c:607:    g_source_set_dummy_callback (cancellable_source);<br>agent/outputstream.c:635:    g_source_set_dummy_callback (cancellable_source);<br>agent/inputstream.c:475:    g_source_set_dummy_callback (cancellable_source);<br>agent/component.c:151:  g_source_set_dummy_callback (component->stop_cancellable_source);<br>agent/component.c:1032:    g_source_set_dummy_callback (child_socket_source->source);<br>agent/component.c:1177:    g_source_set_dummy_callback (cancellable_source);<br>tests/test-new-dribble.c:732:  g_source_set_dummy_callback (src);<br><br><br></div></div>I hope this can help you ;).<br><br></div><div class="gmail_extra"><br><div class="gmail_quote">2015-04-15 13:08 GMT+02:00 Miguel París Díaz <span dir="ltr"><<a href="mailto:mparisdiaz@gmail.com" target="_blank">mparisdiaz@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Yes, you are right, sorry for not sending a complete report.<br></div>I will do it when I can and send the report again ;).<br></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">2015-04-13 16:32 GMT+02:00 Philip Withnall <span dir="ltr"><<a href="mailto:philip@tecnocode.co.uk" target="_blank">philip@tecnocode.co.uk</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<span><br>
On Mon, 2015-04-13 at 13:10 +0200, Miguel París Díaz wrote:<br>
> Hello,<br>
><br>
> I have tested my system with valgrind and I have seen some memory<br>
> leaks into libnice v0.1.10.<br>
> Valgind does not detect any memory leak running the same tests with<br>
> v0.1.7.<br>
><br>
> I hope this can help you to fix them ;).<br>
<br>
</span>Not really, without the necessary debug symbols (replacing the ‘???’<br>
entries in the stack traces below).<br>
<br>
Can you please install the debug info package for your distribution for<br>
libnice, or recompile it with debug symbols enabled; then produce a new<br>
set of leak traces with valgrind?<br>
<br>
Thanks,<br>
Philip<br>
<br>
</blockquote></div><br><br clear="all"><br></div></div><span class="">-- <br><div><div dir="ltr">Miguel París Díaz<br>------------------------------------------------------------------------<br>Computer/Software engineer.<br>Researcher and architect in <a href="http://www.kurento.org" target="_blank">http://www.kurento.org</a><br><a href="http://twitter.com/mparisdiaz" target="_blank">http://twitter.com/mparisdiaz</a><br>------------------------------------------------------------------------<br></div></div>
</span></div>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr">Miguel París Díaz<br>------------------------------------------------------------------------<br>Computer/Software engineer.<br>Researcher and architect in <a href="http://www.kurento.org" target="_blank">http://www.kurento.org</a><br><a href="http://twitter.com/mparisdiaz" target="_blank">http://twitter.com/mparisdiaz</a><br>------------------------------------------------------------------------<br></div></div>
</div>