[gst-cvs] gnonlin: gnlghostpad: add G_UNLIKELY and remove useless warning
Edward Hervey
bilboed at kemper.freedesktop.org
Fri Jun 12 09:49:23 PDT 2009
Module: gnonlin
Branch: master
Commit: 344a24557149e8383b1d39cdeff3791c8b2a4d5f
URL: http://cgit.freedesktop.org/gstreamer/gnonlin/commit/?id=344a24557149e8383b1d39cdeff3791c8b2a4d5f
Author: Edward Hervey <bilboed at bilboed.com>
Date: Fri Jun 12 18:42:25 2009 +0200
gnlghostpad: add G_UNLIKELY and remove useless warning
---
gnl/gnlghostpad.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/gnl/gnlghostpad.c b/gnl/gnlghostpad.c
index 3e69b76..77cfe88 100644
--- a/gnl/gnlghostpad.c
+++ b/gnl/gnlghostpad.c
@@ -658,7 +658,7 @@ control_internal_pad (GstPad * ghostpad, GnlObject * object)
internal = gst_pad_get_peer (target);
gst_object_unref (target);
- if (!(priv = gst_pad_get_element_private (internal))) {
+ if (G_UNLIKELY (!(priv = gst_pad_get_element_private (internal)))) {
GST_DEBUG_OBJECT (internal,
"Creating a GnlPadPrivate to put in element_private");
priv = g_new0 (GnlPadPrivate, 1);
@@ -676,9 +676,6 @@ control_internal_pad (GstPad * ghostpad, GnlObject * object)
GST_DEBUG_FUNCPTR (internalpad_event_function));
gst_pad_set_query_function (internal,
GST_DEBUG_FUNCPTR (internalpad_query_function));
- } else {
- GST_WARNING_OBJECT (internal,
- "internal pad already had an element_private");
}
priv->object = object;
More information about the Gstreamer-commits
mailing list