[glabels/glabels_2_2] Add place-holder field to all empty private structures



commit 333e792ab9daa4cb6fba8f19d360ca27d69ebff0
Author: Jim Evins <evins snaught com>
Date:   Sun Apr 11 00:05:30 2010 -0400

    Add place-holder field to all empty private structures
    
    Fixes glabels bug #2981895.  This is a work-around for glib bug #615379.  For
    objects with no private data, add a place-holder field so that the private
    structure is not of zero length which causes g_new0() to crash in glib
    2.24.0.

 src/view-barcode.c |    1 +
 src/view-box.c     |    1 +
 src/view-ellipse.c |    1 +
 src/view-image.c   |    1 +
 src/view-line.c    |    1 +
 src/view-text.c    |    1 +
 6 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/view-barcode.c b/src/view-barcode.c
index 522d334..02b8f9f 100644
--- a/src/view-barcode.c
+++ b/src/view-barcode.c
@@ -46,6 +46,7 @@
 /*========================================================*/
 
 struct _glViewBarcodePrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/
diff --git a/src/view-box.c b/src/view-box.c
index 42f3980..4d0941f 100644
--- a/src/view-box.c
+++ b/src/view-box.c
@@ -47,6 +47,7 @@
 /*========================================================*/
 
 struct _glViewBoxPrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/
diff --git a/src/view-ellipse.c b/src/view-ellipse.c
index 8547470..6d86b5a 100644
--- a/src/view-ellipse.c
+++ b/src/view-ellipse.c
@@ -48,6 +48,7 @@
 /*========================================================*/
 
 struct _glViewEllipsePrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/
diff --git a/src/view-image.c b/src/view-image.c
index 7612284..b546baf 100644
--- a/src/view-image.c
+++ b/src/view-image.c
@@ -47,6 +47,7 @@
 /*========================================================*/
 
 struct _glViewImagePrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/
diff --git a/src/view-line.c b/src/view-line.c
index 12f29a4..8c39965 100644
--- a/src/view-line.c
+++ b/src/view-line.c
@@ -47,6 +47,7 @@
 /*========================================================*/
 
 struct _glViewLinePrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/
diff --git a/src/view-text.c b/src/view-text.c
index ca93012..527c307 100644
--- a/src/view-text.c
+++ b/src/view-text.c
@@ -46,6 +46,7 @@
 /*========================================================*/
 
 struct _glViewTextPrivate {
+        int place_holder; /* Place holder for future private data. */
 };
 
 /*========================================================*/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]