From efafdb2aa61a65ec124ce9cb8bd70225076ebc15 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Fri, 12 Jul 2002 19:13:19 +0000 Subject: [PATCH] be more lenient when loading unconnected pads Original commit message from CVS: be more lenient when loading unconnected pads --- gst/cothreads.c | 4 +--- gst/gstpad.c | 6 ++++++ gst/gstplugin.c | 9 --------- 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/gst/cothreads.c b/gst/cothreads.c index a4d7257a11..5a32c6d84b 100644 --- a/gst/cothreads.c +++ b/gst/cothreads.c @@ -497,10 +497,8 @@ cothread_stackquery (void **stack, glong* stacksize) { /* wingo says: use posix_memalign to allocate a 2M-aligned, 2M stack */ - int retval = 0; - #ifdef HAVE_POSIX_MEMALIGN - retval = posix_memalign (stack, STACK_SIZE, STACK_SIZE); + int retval = posix_memalign (stack, STACK_SIZE, STACK_SIZE); if (retval != 0) { g_warning ("Could not posix_memalign stack !\n"); diff --git a/gst/gstpad.c b/gst/gstpad.c index 29a7e75a0f..f4781909ff 100644 --- a/gst/gstpad.c +++ b/gst/gstpad.c @@ -1732,6 +1732,12 @@ gst_pad_load_and_connect (xmlNodePtr self, split = g_strsplit (peer, ".", 2); + if (split[0] == NULL || split[1] == NULL) { + GST_DEBUG (GST_CAT_XML, "Could not parse peer '%s' for pad %s:%s, leaving it unconnected", + peer, GST_DEBUG_PAD_NAME (pad)); + return; + } + g_return_if_fail (split[0] != NULL); g_return_if_fail (split[1] != NULL); diff --git a/gst/gstplugin.c b/gst/gstplugin.c index 273078d3a0..e80cb0d65f 100644 --- a/gst/gstplugin.c +++ b/gst/gstplugin.c @@ -218,15 +218,6 @@ gst_plugin_load_plugin (GstPlugin *plugin, GError **error) filename, g_module_error()); return FALSE; } - - /* FIXME: this should not happen */ - g_set_error (error, - GST_PLUGIN_ERROR, - GST_PLUGIN_ERROR_MODULE, - "Error loading plugin %s, reason: %s\n", - filename, - "fell of the end of the gst_plugin_load_plugin function"); - return FALSE; }