On Thu, 2012-05-10 at 23:03 -0400, José Alburquerque wrote: > On Thu, 2012-05-10 at 17:56 -0400, Kurt Miller wrote: > > Using gstreamermm-0.10.10.1 with gstreamer-0.10.36 Gst::init() > > indirectly attempts a recursive load of the adder plugin. The > > recursive load deadlocks due to the use of a static mutex in > > gst_plugin_load_by_name(). This is reproduceable with > > subtitleeditor on OpenBSD HEAD/current. > > > > Here is the stack trace showing the recursive call to > > gst_plugin_load_by_name(): > > > > #2 0x0009c065 in _rthread_mutex_lock (mutexp=0x7c1e6670, trywait=0, > > abstime=0x0) at /usr/src/lib/librthread/rthread_sync.c:127 > > #3 0x08c68ec2 in g_mutex_lock () from /usr/local/lib/libglib-2.0.so.3200.0 > > #4 0x02f1f3e5 in gst_plugin_load_file (filename=0x7c1f6580 > > "/usr/local/lib/gstreamer-0.10/libgstadder.so", error=0xcfbc0bc8) > > at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:722 > > #5 0x02f2022b in gst_plugin_load_by_name (name=0x7c3c2bf5 "adder") at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1297 > > #6 0x02f2185d in gst_plugin_feature_load (feature=0x7c3c32e8) at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:111 > > #7 0x0b5e3954 in gst_adder_get_type () at > > /usr/obj/ports/gstreamermm-0.10.10.1/gstreamermm-0.10.10.1/gstreamer/gstreamermm/adder.cc:29 > > #8 0x0ff679e1 in plugin_init (plugin=0x7c397d48) at > > /usr/obj/ports/gst-plugins-base-0.10.36/gst-plugins-base-0.10.36/gst/adder/gstadder.c:1322 > > #9 0x02f1e6ff in gst_plugin_register_func (plugin=0x7c397d48, > > desc=0x2ff66020, user_data=0x0) > > at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:557 > > #10 0x02f1f611 in gst_plugin_load_file (filename=0x7c1f6580 > > "/usr/local/lib/gstreamer-0.10/libgstadder.so", error=0xcfbc0dc8) > > at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:843 > > #11 0x02f2022b in gst_plugin_load_by_name (name=0x7c3c2bf5 "adder") at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1297 > > #12 0x02f2185d in gst_plugin_feature_load (feature=0x7c3c32e8) at > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:111 > > #13 0x0b5e3954 in gst_adder_get_type () at > > /usr/obj/ports/gstreamermm-0.10.10.1/gstreamermm-0.10.10.1/gstreamer/gstreamermm/adder.cc:29 > > #14 0x0b624d21 in Gst::wrap_init () at > > /usr/obj/ports/gstreamermm-0.10.10.1/gstreamermm-0.10.10.1/gstreamer/gstreamermm/wrap_init.cc:386 > > #15 0x0b6258d0 in initialize_wrap_system () at > > /usr/obj/ports/gstreamermm-0.10.10.1/gstreamermm-0.10.10.1/gstreamer/gstreamermm/init.cc:36 > > #16 0x0b625a77 in Gst::init (argc=@0xcfbc0fb4, argv=@0xcfbc0fb8) > > at > > /usr/obj/ports/gstreamermm-0.10.10.1/gstreamermm-0.10.10.1/gstreamer/gstreamermm/init.cc:53 > > #17 0x1c01d13c in Glib::PropertyProxy<Glib::ustring>::get_value () > > > > Here are the debug messages: > > > > GST_INIT > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gst.c:805:init_post: > > GLib runtime version: 2.32.2 > > GST_INIT > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gst.c:807:init_post: > > GLib headers version: 2.32.2 > > GST_INIT > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gst.c:437:gst_init_check: > > already initialized gst > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<adder> > > 0x7c3c32e8 ref 1->2 > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:106:gst_plugin_feature_load: > > loading plugin for feature 0x7c3c32e8; 'adder' > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:110:gst_plugin_feature_load: > > loading plugin adder > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1293:gst_plugin_load_by_name: > > looking up plugin adder in default registry > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<plugin96> > > 0x7c397d48 ref 1->2 > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<plugin96> > > 0x7c397d48 ref 2->3 > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:337:gst_object_unref:<plugin96> > > 0x7c397d48 unref 3->2 > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1296:gst_plugin_load_by_name: > > loading plugin adder from file /usr/local/lib/gstreamer-0.10/libgstadder.so > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<plugin96> > > 0x7c397d48 ref 2->3 > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:737:gst_plugin_load_file: > > attempt to load plugin "/usr/local/lib/gstreamer-0.10/libgstadder.so" > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:834:gst_plugin_load_file: > > Plugin 0x7c397d48 for file "/usr/local/lib/gstreamer-0.10/libgstadder.so" > > prepared, calling entry function... > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:841:gst_plugin_load_file: > > Plugin 0x7c397d48 for file "/usr/local/lib/gstreamer-0.10/libgstadder.so" > > prepared, registering... > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:540:gst_plugin_register_func: > > plugin "/usr/local/lib/gstreamer-0.10/libgstadder.so" looks good > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<adder> > > 0x7c3c32e8 ref 2->3 > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:106:gst_plugin_feature_load: > > loading plugin for feature 0x7c3c32e8; 'adder' > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstpluginfeature.c:110:gst_plugin_feature_load: > > loading plugin adder > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1293:gst_plugin_load_by_name: > > looking up plugin adder in default registry > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<plugin96> > > 0x7c397d48 ref 3->4 > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:311:gst_object_ref:<plugin96> > > 0x7c397d48 ref 4->5 > > GST_REFCOUNTING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstobject.c:337:gst_object_unref:<plugin96> > > 0x7c397d48 unref 5->4 > > GST_PLUGIN_LOADING > > /usr/obj/ports/gstreamer-0.10.36/gstreamer-0.10.36/gst/gstplugin.c:1296:gst_plugin_load_by_name: > > loading plugin adder from file /usr/local/lib/gstreamer-0.10/libgstadder.so > > > > It is not clear to me what globals are being protected by the > > gst_plugin_loading_mutex in gst/gstplugin.c gst_plugin_load_file(). > > Perhaps the scope of the lock is to0 broad covering the potential > > recursion caused by the call to gst_plugin_register_func(). > > > > Any pointers on how to address this problem would be appreciated. > > I can't reproduce this on an ubuntu 12.04 system using the same > versions of GStreamer and gstreamermm. 'make check' of the > gstreamermm-0.10.10.1 tarball succeeds (building and running the tests > which all call Gst::init()). Also, the hello_world example works just > fine.
I've also built and tested subtitleeditor-0.40.0 using the above versions of GStreamer and gstreamermm and it runs fine here. -- José _______________________________________________ gtkmm-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/gtkmm-list
