Added parameter checking to gst_queue_get().

Original commit message from CVS:
Added parameter checking to gst_queue_get().
This commit is contained in:
David I. Lehn 2001-02-21 20:27:54 +00:00
parent a9f3deea80
commit 0edc93ae29
2 changed files with 10 additions and 2 deletions

View file

@ -251,11 +251,15 @@ gst_queue_chain (GstPad *pad, GstBuffer *buf)
static GstBuffer *
gst_queue_get (GstPad *pad)
{
GstQueue *queue = GST_QUEUE (GST_OBJECT_PARENT (pad));
GstQueue *queue;
GstBuffer *buf = NULL;
GSList *front;
const guchar *name;
g_return_val_if_fail (pad != NULL, NULL);
g_return_val_if_fail (GST_IS_PAD (pad), NULL);
queue = GST_QUEUE (GST_OBJECT_PARENT (pad));
name = GST_ELEMENT_NAME (queue);
/* have to lock for thread-safety */

View file

@ -251,11 +251,15 @@ gst_queue_chain (GstPad *pad, GstBuffer *buf)
static GstBuffer *
gst_queue_get (GstPad *pad)
{
GstQueue *queue = GST_QUEUE (GST_OBJECT_PARENT (pad));
GstQueue *queue;
GstBuffer *buf = NULL;
GSList *front;
const guchar *name;
g_return_val_if_fail (pad != NULL, NULL);
g_return_val_if_fail (GST_IS_PAD (pad), NULL);
queue = GST_QUEUE (GST_OBJECT_PARENT (pad));
name = GST_ELEMENT_NAME (queue);
/* have to lock for thread-safety */