From 3031f4ae35c7a3b65345cc727c68f447e3d9121c Mon Sep 17 00:00:00 2001 From: Julien Moutte Date: Mon, 12 Jan 2004 14:40:53 +0000 Subject: [PATCH] sys/: Fixing the direct put buffers detection. I prefer checking GST_BUFFER_PRIVATE than the free_func. Original commit message from CVS: 2004-01-12 Julien MOUTTE * sys/ximage/ximagesink.c: (gst_ximagesink_chain): * sys/xvimage/xvimagesink.c: (gst_xvimagesink_chain): Fixing the direct put buffers detection. I prefer checking GST_BUFFER_PRIVATE than the free_func. --- ChangeLog | 7 +++++++ sys/ximage/ximagesink.c | 5 +---- sys/xvimage/xvimagesink.c | 5 +---- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2b2f497de..add26c205 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2004-01-12 Julien MOUTTE + + * sys/ximage/ximagesink.c: (gst_ximagesink_chain): + * sys/xvimage/xvimagesink.c: (gst_xvimagesink_chain): Fixing the + direct put buffers detection. I prefer checking GST_BUFFER_PRIVATE + than the free_func. + 2004-01-12 Thomas Vander Stichele * sys/oss/gstossaudio.c: (plugin_init): diff --git a/sys/ximage/ximagesink.c b/sys/ximage/ximagesink.c index 61a6a39cc..942bb456e 100644 --- a/sys/ximage/ximagesink.c +++ b/sys/ximage/ximagesink.c @@ -49,8 +49,6 @@ GST_STATIC_PAD_TEMPLATE ( "height = (int) [ 0, MAX ]") ); -static void gst_ximagesink_buffer_free (GstBuffer *buffer); - static GstVideoSinkClass *parent_class = NULL; /* ============================================================= */ @@ -741,8 +739,7 @@ gst_ximagesink_chain (GstPad *pad, GstData *data) /* If this buffer has been allocated using our buffer management we simply put the ximage which is in the PRIVATE pointer */ - /* FIXME: need to check for correct xvimagesink here? */ - if (GST_BUFFER_FREE_DATA_FUNC (buf) == gst_ximagesink_buffer_free) + if (GST_BUFFER_PRIVATE (buf)) { gst_ximagesink_ximage_put (ximagesink, GST_BUFFER_PRIVATE (buf)); } diff --git a/sys/xvimage/xvimagesink.c b/sys/xvimage/xvimagesink.c index 99e9f77b2..a9f6d16bb 100644 --- a/sys/xvimage/xvimagesink.c +++ b/sys/xvimage/xvimagesink.c @@ -55,8 +55,6 @@ GST_STATIC_PAD_TEMPLATE ( ) ); -static void gst_xvimagesink_buffer_free (GstBuffer *buffer); - static GstVideoSinkClass *parent_class = NULL; /* ============================================================= */ @@ -901,8 +899,7 @@ gst_xvimagesink_chain (GstPad *pad, GstData *data) /* If this buffer has been allocated using our buffer management we simply put the ximage which is in the PRIVATE pointer */ - /* FIXME: need to check for correct xvimagesink here? */ - if (GST_BUFFER_FREE_DATA_FUNC (buf) == gst_xvimagesink_buffer_free) + if (GST_BUFFER_PRIVATE (buf)) { gst_xvimagesink_xvimage_put (xvimagesink, GST_BUFFER_PRIVATE (buf)); } -- 2.34.1