From: Julien Moutte Date: Tue, 17 Feb 2004 22:55:26 +0000 (+0000) Subject: gst/gstpad.c: Reverting my change according to what we agreed with david. X-Git-Tag: BRANCH-RELEASE-0_7_5-ROOT~21 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6aeaab96430a539a769b05c4fc6b535dbcf598ec;p=platform%2Fupstream%2Fgstreamer.git gst/gstpad.c: Reverting my change according to what we agreed with david. Original commit message from CVS: 2004-02-17 Julien MOUTTE * gst/gstpad.c: (gst_pad_try_set_caps): Reverting my change according to what we agreed with david. * gst/gstpad.h: adding GST_PAD_IS_NEGOTIATING macro. --- diff --git a/ChangeLog b/ChangeLog index a10d18c..49f2f78 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-02-17 Julien MOUTTE + + * gst/gstpad.c: (gst_pad_try_set_caps): Reverting my change according + to what we agreed with david. + * gst/gstpad.h: adding GST_PAD_IS_NEGOTIATING macro. + 2004-02-17 Thomas Vander Stichele * po/nl.po: update translation diff --git a/gst/gstpad.c b/gst/gstpad.c index d70e372..567f0c3 100644 --- a/gst/gstpad.c +++ b/gst/gstpad.c @@ -1408,10 +1408,7 @@ gst_pad_try_set_caps (GstPad *pad, const GstCaps *caps) g_return_val_if_fail (pad != NULL, GST_PAD_LINK_REFUSED); g_return_val_if_fail (GST_IS_REAL_PAD (pad), GST_PAD_LINK_REFUSED); - - /* If the pad is negotiating we refuse this try */ - if (GST_FLAG_IS_SET (pad, GST_PAD_NEGOTIATING)) - return GST_PAD_LINK_REFUSED; + g_return_val_if_fail (!GST_PAD_IS_NEGOTIATING (pad), GST_PAD_LINK_REFUSED); /* setting non-fixed caps on a pad is not allowed */ if (!gst_caps_is_fixed (caps)) { diff --git a/gst/gstpad.h b/gst/gstpad.h index 691ea5f..c8702a9 100644 --- a/gst/gstpad.h +++ b/gst/gstpad.h @@ -279,6 +279,7 @@ struct _GstGhostPadClass { /* Some check functions (unused?) */ #define GST_PAD_IS_LINKED(pad) (GST_PAD_PEER(pad) != NULL) #define GST_PAD_IS_ACTIVE(pad) (!GST_FLAG_IS_SET(GST_PAD_REALIZE(pad), GST_PAD_DISABLED)) +#define GST_PAD_IS_NEGOTIATING(pad) (GST_FLAG_IS_SET (pad, GST_PAD_NEGOTIATING)) #define GST_PAD_IS_USABLE(pad) (GST_PAD_IS_LINKED (pad) && \ GST_PAD_IS_ACTIVE(pad) && GST_PAD_IS_ACTIVE(GST_PAD_PEER (pad))) #define GST_PAD_CAN_PULL(pad) (GST_IS_REAL_PAD(pad) && GST_REAL_PAD(pad)->gethandler != NULL) @@ -516,4 +517,3 @@ G_END_DECLS #endif /* __GST_PAD_H__ */ -