[glib: 6/15] Fix missing initializer warnings in glib/tests/markup-collect.c




commit 24c60cee6c5de50b38c535e00e9741becf28c76c
Author: Emmanuel Fleury <emmanuel fleury gmail com>
Date:   Sun Nov 8 21:24:07 2020 +0100

    Fix missing initializer warnings in glib/tests/markup-collect.c
    
    glib/gmarkup.h:154:10: note: ‘end_element’ declared here
      154 |   void (*end_element)    (GMarkupParseContext *context,
          |          ^~~~~~~~~~~
    glib/tests/markup-collect.c:94:3: error: missing initializer for field ‘error_code’ of ‘struct test’
       94 |   { "<bool mb='false'/>", "<bool(1) 0 0 -1>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:95:3: error: missing initializer for field ‘error_code’ of ‘struct test’
       95 |   { "<bool mb='true'/>", "<bool(1) 1 0 -1>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:96:3: error: missing initializer for field ‘error_code’ of ‘struct test’
       96 |   { "<bool mb='t' ob='f' tri='1'/>", "<bool(1) 1 0 1>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:97:3: error: missing initializer for field ‘error_code’ of ‘struct test’
       97 |   { "<bool mb='y' ob='n' tri='0'/>", "<bool(1) 1 0 0>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:99:3: error: missing initializer for field ‘error_code’ of ‘struct test’
       99 |   { "<bool mb='y' my:attr='q'><my:tag/></bool>", "<bool(1) 1 0 -1>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:100:3: error: missing initializer for field ‘error_code’ of ‘struct test’
      100 |   { "<bool mb='y' my:attr='q'><my:tag>some <b>text</b> is in here</my:tag></bool>", "<bool(1) 1 0 
-1>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~
    glib/tests/markup-collect.c:111:3: error: missing initializer for field ‘error_code’ of ‘struct test’
      111 |   { "<str cm='x' am='y'/>", "<str(1) x y (null) (null)>" },
          |   ^
    glib/tests/markup-collect.c:85:17: note: ‘error_code’ declared here
       85 |   GMarkupError  error_code;
          |                 ^~~~~~~~~~

 glib/tests/markup-collect.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
---
diff --git a/glib/tests/markup-collect.c b/glib/tests/markup-collect.c
index 0c2757a34..b796b4238 100644
--- a/glib/tests/markup-collect.c
+++ b/glib/tests/markup-collect.c
@@ -91,13 +91,14 @@ static struct test tests[] =
   { "<bool mb='y'>", "<bool(1) 1 0 -1>",
     G_MARKUP_ERROR_PARSE, "'bool'" },
 
-  { "<bool mb='false'/>", "<bool(1) 0 0 -1>" },
-  { "<bool mb='true'/>", "<bool(1) 1 0 -1>" },
-  { "<bool mb='t' ob='f' tri='1'/>", "<bool(1) 1 0 1>" },
-  { "<bool mb='y' ob='n' tri='0'/>", "<bool(1) 1 0 0>" },
+  { "<bool mb='false'/>", "<bool(1) 0 0 -1>", 0, NULL },
+  { "<bool mb='true'/>", "<bool(1) 1 0 -1>", 0, NULL },
+  { "<bool mb='t' ob='f' tri='1'/>", "<bool(1) 1 0 1>", 0, NULL },
+  { "<bool mb='y' ob='n' tri='0'/>", "<bool(1) 1 0 0>", 0, NULL },
 
-  { "<bool mb='y' my:attr='q'><my:tag/></bool>", "<bool(1) 1 0 -1>" },
-  { "<bool mb='y' my:attr='q'><my:tag>some <b>text</b> is in here</my:tag></bool>", "<bool(1) 1 0 -1>" },
+  { "<bool mb='y' my:attr='q'><my:tag/></bool>", "<bool(1) 1 0 -1>", 0, NULL },
+  { "<bool mb='y' my:attr='q'><my:tag>some <b>text</b> is in here</my:tag></bool>",
+    "<bool(1) 1 0 -1>", 0, NULL },
 
   { "<bool ob='y'/>", "<bool(0) 0 0 -1>",
     G_MARKUP_ERROR_MISSING_ATTRIBUTE, "'mb'" },
@@ -108,7 +109,7 @@ static struct test tests[] =
   { "<bool mb='y' tri='y' tri='n'/>", "<bool(0) 0 0 -1>",
     G_MARKUP_ERROR_INVALID_CONTENT, "'tri'" },
 
-  { "<str cm='x' am='y'/>", "<str(1) x y (null) (null)>" },
+  { "<str cm='x' am='y'/>", "<str(1) x y (null) (null)>", 0, NULL },
 
   { "<str am='x' co='y'/>", "<str(0) (null) (null) (null) (null)>",
     G_MARKUP_ERROR_MISSING_ATTRIBUTE, "'cm'" },


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