meta: remove unnecessary padding for GstMetaInfo struct
authorTim-Philipp Müller <tim@centricular.com>
Fri, 2 Dec 2016 15:30:59 +0000 (15:30 +0000)
committerTim-Philipp Müller <tim@centricular.com>
Mon, 5 Dec 2016 20:35:41 +0000 (20:35 +0000)
This structure is always allocated by GStreamer, can't be
subclassed or extended, and is never allocated or used on
the stack, so we don't need any padding and can extend it
as we please.

gst/gstmeta.h
tests/check/gst/struct_arm.h
tests/check/gst/struct_hppa.h
tests/check/gst/struct_i386.h
tests/check/gst/struct_i386w.h
tests/check/gst/struct_ppc32.h
tests/check/gst/struct_ppc64.h
tests/check/gst/struct_sparc.h
tests/check/gst/struct_x86_64.h

index b5db1d5..d6aaa67 100644 (file)
@@ -197,8 +197,9 @@ struct _GstMetaInfo {
   GstMetaFreeFunction        free_func;
   GstMetaTransformFunction   transform_func;
 
-  /*< private >*/
-  gpointer _gst_reserved[GST_PADDING];
+  /* No padding needed, GstMetaInfo is always allocated by GStreamer and is
+   * not subclassable or stack-allocatable, so we can extend it as we please
+   * just like interfaces */
 };
 
 GType                gst_meta_api_type_register (const gchar *api,
index 7660266..3f7be8a 100644 (file)
@@ -32,7 +32,6 @@ GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 80},
   {"GstMeta", sizeof (GstMeta), 8},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 12},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 40},
   {"GstMiniObject", sizeof (GstMiniObject), 36},
   {"GstObjectClass", sizeof (GstObjectClass), 92},
   {"GstObject", sizeof (GstObject), 64},
index 5794580..2708df0 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 120},
   {"GstMeta", sizeof (GstMeta), 16},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 24},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 80},
   {"GstMiniObject", sizeof (GstMiniObject), 64},
   {"GstObjectClass", sizeof (GstObjectClass), 184},
   {"GstObject", sizeof (GstObject), 88},
index 33363e6..015ee64 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 76},
   {"GstMeta", sizeof (GstMeta), 8},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 12},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 40},
   {"GstMiniObject", sizeof (GstMiniObject), 36},
   {"GstObjectClass", sizeof (GstObjectClass), 92},
   {"GstObject", sizeof (GstObject), 56},
index 91c0386..5d985ac 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 80},
   {"GstMeta", sizeof (GstMeta), 8},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 12},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 40},
   {"GstMiniObject", sizeof (GstMiniObject), 36},
   {"GstObjectClass", sizeof (GstObjectClass), 92},
   {"GstObject", sizeof (GstObject), 64},
index 91c0386..5d985ac 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 80},
   {"GstMeta", sizeof (GstMeta), 8},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 12},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 40},
   {"GstMiniObject", sizeof (GstMiniObject), 36},
   {"GstObjectClass", sizeof (GstObjectClass), 92},
   {"GstObject", sizeof (GstObject), 64},
index 5794580..2708df0 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 120},
   {"GstMeta", sizeof (GstMeta), 16},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 24},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 80},
   {"GstMiniObject", sizeof (GstMiniObject), 64},
   {"GstObjectClass", sizeof (GstObjectClass), 184},
   {"GstObject", sizeof (GstObject), 88},
index 5794580..2708df0 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 120},
   {"GstMeta", sizeof (GstMeta), 16},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 24},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 80},
   {"GstMiniObject", sizeof (GstMiniObject), 64},
   {"GstObjectClass", sizeof (GstObjectClass), 184},
   {"GstObject", sizeof (GstObject), 88},
index 5794580..2708df0 100644 (file)
@@ -31,7 +31,6 @@ static GstCheckABIStruct list[] = {
   {"GstMessage", sizeof (GstMessage), 120},
   {"GstMeta", sizeof (GstMeta), 16},
   {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 24},
-  {"GstMetaInfo", sizeof (GstMetaInfo), 80},
   {"GstMiniObject", sizeof (GstMiniObject), 64},
   {"GstObjectClass", sizeof (GstObjectClass), 184},
   {"GstObject", sizeof (GstObject), 88},