Appsink: add padding for callbacks + docs

Add some padding to the callbacks structure just to be safe.

Remove the now invisible marshaller methods from the docs.

Fix a comment in the unit test.
This commit is contained in:
Wim Taymans 2009-02-26 11:42:44 +01:00
parent 7f8933c918
commit 661f2da6e0
3 changed files with 4 additions and 5 deletions

View file

@ -37,10 +37,6 @@ GstAppBufferClass
GstAppBufferFinalizeFunc
gst_app_buffer_get_type
gst_app_buffer_new
gst_app_marshal_BOOLEAN__UINT64
gst_app_marshal_ENUM__OBJECT
gst_app_marshal_ENUM__VOID
gst_app_marshal_VOID__UINT
</SECTION>
<SECTION>

View file

@ -64,6 +64,9 @@ typedef struct {
void (*eos) (GstAppSink *sink, gpointer user_data);
void (*new_preroll) (GstAppSink *sink, gpointer user_data);
void (*new_buffer) (GstAppSink *sink, gpointer user_data);
/*< private >*/
gpointer _gst_reserved[GST_PADDING];
} GstAppSinkCallbacks;
struct _GstAppSink

View file

@ -185,6 +185,7 @@ GST_START_TEST (test_notify1)
gst_app_sink_set_callbacks (GST_APP_SINK (sink), &callbacks,
&testdata, (*notify_function));
/* Setting new callbacks should trigger the destroy of the old data */
gst_app_sink_set_callbacks (GST_APP_SINK (sink), &callbacks, &testdata, NULL);
testdata = operate_on_data (testdata);
@ -193,7 +194,6 @@ GST_START_TEST (test_notify1)
fail_unless (testdata == global_testdata);
GST_DEBUG ("cleaning up appsink");
/* Destroying sink should call our notify_function */
gst_object_unref (sink);
}