From 8045b77c323370b15e7c6e9812daff2e85b4182b Mon Sep 17 00:00:00 2001 From: Emmanuel Fleury Date: Sun, 8 Nov 2020 22:28:37 +0100 Subject: [PATCH] Fixing missing initializer warnings in glib/tests/option-context.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit glib/tests/option-context.c: In function ‘callback_test_optional_5’: glib/tests/option-context.c:945:5: error: missing initializer for field ‘arg_description’ of ‘GOptionEntry’ {aka ‘struct _GOptionEntry’} 945 | { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, | ^ In file included from glib/glib.h:64, from glib/tests/option-context.c:23: glib/goption.h:268:16: note: ‘arg_description’ declared here 268 | const gchar *arg_description; | ^~~~~~~~~~~~~~~ glib/tests/option-context.c: In function ‘callback_test_optional_6’: glib/tests/option-context.c:983:5: error: missing initializer for field ‘arg_description’ of ‘GOptionEntry’ {aka ‘struct _GOptionEntry’} 983 | { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, | ^ In file included from glib/glib.h:64, from glib/tests/option-context.c:23: glib/goption.h:268:16: note: ‘arg_description’ declared here 268 | const gchar *arg_description; | ^~~~~~~~~~~~~~~ glib/tests/option-context.c: In function ‘callback_test_optional_7’: glib/tests/option-context.c:1021:5: error: missing initializer for field ‘arg_description’ of ‘GOptionEntry’ {aka ‘struct _GOptionEntry’} 1021 | { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, | ^ In file included from glib/glib.h:64, from glib/tests/option-context.c:23: glib/goption.h:268:16: note: ‘arg_description’ declared here 268 | const gchar *arg_description; | ^~~~~~~~~~~~~~~ glib/tests/option-context.c: In function ‘callback_test_optional_8’: glib/tests/option-context.c:1059:5: error: missing initializer for field ‘arg_description’ of ‘GOptionEntry’ {aka ‘struct _GOptionEntry’} 1059 | { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, | ^ In file included from glib/glib.h:64, from glib/tests/option-context.c:23: glib/goption.h:268:16: note: ‘arg_description’ declared here 268 | const gchar *arg_description; | ^~~~~~~~~~~~~~~ --- glib/tests/option-context.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/glib/tests/option-context.c b/glib/tests/option-context.c index 68e990db0..ec66e6f94 100644 --- a/glib/tests/option-context.c +++ b/glib/tests/option-context.c @@ -943,7 +943,7 @@ callback_test_optional_5 (void) gchar **argv_copy; int argc; GOptionEntry entries [] = - { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, + { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL, NULL }, { "test", 't', G_OPTION_FLAG_OPTIONAL_ARG, G_OPTION_ARG_CALLBACK, callback_parse_optional, NULL, NULL }, { NULL } }; @@ -981,7 +981,7 @@ callback_test_optional_6 (void) gchar **argv_copy; int argc; GOptionEntry entries [] = - { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, + { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL, NULL }, { "test", 't', G_OPTION_FLAG_OPTIONAL_ARG, G_OPTION_ARG_CALLBACK, callback_parse_optional, NULL, NULL }, { NULL } }; @@ -1019,7 +1019,7 @@ callback_test_optional_7 (void) gchar **argv_copy; int argc; GOptionEntry entries [] = - { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, + { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL, NULL }, { "test", 't', G_OPTION_FLAG_OPTIONAL_ARG, G_OPTION_ARG_CALLBACK, callback_parse_optional, NULL, NULL }, { NULL } }; @@ -1057,7 +1057,7 @@ callback_test_optional_8 (void) gchar **argv_copy; int argc; GOptionEntry entries [] = - { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL }, + { { "dummy", 'd', 0, G_OPTION_ARG_NONE, &dummy, NULL, NULL }, { "test", 't', G_OPTION_FLAG_OPTIONAL_ARG, G_OPTION_ARG_CALLBACK, callback_parse_optional, NULL, NULL }, { NULL } };