diff --git a/gio/gasynchelper.c b/gio/gasynchelper.c index fa63dfee9..4928115d8 100644 --- a/gio/gasynchelper.c +++ b/gio/gasynchelper.c @@ -87,8 +87,8 @@ fd_source_closure_callback (int fd, { GClosure *closure = data; - GValue params[2] = { { 0, }, { 0, } }; - GValue result_value = { 0, }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; + GValue result_value = G_VALUE_INIT; gboolean result; g_value_init (&result_value, G_TYPE_BOOLEAN); diff --git a/gio/gcancellable.c b/gio/gcancellable.c index 1a6785823..06d2fa7d7 100644 --- a/gio/gcancellable.c +++ b/gio/gcancellable.c @@ -679,8 +679,8 @@ cancellable_source_closure_callback (GCancellable *cancellable, { GClosure *closure = data; - GValue params = { 0, }; - GValue result_value = { 0, }; + GValue params = G_VALUE_INIT; + GValue result_value = G_VALUE_INIT; gboolean result; g_value_init (&result_value, G_TYPE_BOOLEAN); diff --git a/gio/gdbus-2.0/codegen/codegen.py b/gio/gdbus-2.0/codegen/codegen.py index cb9d7759f..8d34bdd11 100644 --- a/gio/gdbus-2.0/codegen/codegen.py +++ b/gio/gdbus-2.0/codegen/codegen.py @@ -2086,7 +2086,7 @@ class CodeGenerator: ' guint num_extra;\n' ' guint n;\n' ' guint signal_id;\n' - ' GValue return_value = {0};\n' + ' GValue return_value = G_VALUE_INIT;\n' %(i.name_lower, i.camel_name, i.ns_upper, i.name_upper)) self.c.write(' info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);\n' ' g_assert (info != NULL);\n' @@ -2149,7 +2149,7 @@ class CodeGenerator: ' gpointer user_data)\n' '{\n' ' %sSkeleton *skeleton = %s%s_SKELETON (user_data);\n' - ' GValue value = {0};\n' + ' GValue value = G_VALUE_INIT;\n' ' GParamSpec *pspec;\n' ' _ExtendedGDBusPropertyInfo *info;\n' ' GVariant *ret;\n' @@ -2186,7 +2186,7 @@ class CodeGenerator: ' gpointer user_data)\n' '{\n' ' %sSkeleton *skeleton = %s%s_SKELETON (user_data);\n' - ' GValue value = {0};\n' + ' GValue value = G_VALUE_INIT;\n' ' GParamSpec *pspec;\n' ' _ExtendedGDBusPropertyInfo *info;\n' ' gboolean ret;\n' diff --git a/gio/gdbusnameowning.c b/gio/gdbusnameowning.c index 4b1c01a0d..65b1227cf 100644 --- a/gio/gdbusnameowning.c +++ b/gio/gdbusnameowning.c @@ -675,7 +675,7 @@ own_with_closures_on_bus_acquired (GDBusConnection *connection, gpointer user_data) { OwnNameData *data = user_data; - GValue params[2] = { { 0, }, { 0, } }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; g_value_init (¶ms[0], G_TYPE_DBUS_CONNECTION); g_value_set_object (¶ms[0], connection); @@ -695,7 +695,7 @@ own_with_closures_on_name_acquired (GDBusConnection *connection, gpointer user_data) { OwnNameData *data = user_data; - GValue params[2] = { { 0, }, { 0, } }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; g_value_init (¶ms[0], G_TYPE_DBUS_CONNECTION); g_value_set_object (¶ms[0], connection); @@ -715,7 +715,7 @@ own_with_closures_on_name_lost (GDBusConnection *connection, gpointer user_data) { OwnNameData *data = user_data; - GValue params[2] = { { 0, }, { 0, } }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; g_value_init (¶ms[0], G_TYPE_DBUS_CONNECTION); g_value_set_object (¶ms[0], connection); diff --git a/gio/gdbusnamewatching.c b/gio/gdbusnamewatching.c index 3f1f54408..bdda901e5 100644 --- a/gio/gdbusnamewatching.c +++ b/gio/gdbusnamewatching.c @@ -687,7 +687,7 @@ watch_with_closures_on_name_appeared (GDBusConnection *connection, gpointer user_data) { WatchNameData *data = user_data; - GValue params[3] = { { 0, }, { 0, }, { 0, } }; + GValue params[3] = { G_VALUE_INIT, G_VALUE_INIT, G_VALUE_INIT }; g_value_init (¶ms[0], G_TYPE_DBUS_CONNECTION); g_value_set_object (¶ms[0], connection); @@ -711,7 +711,7 @@ watch_with_closures_on_name_vanished (GDBusConnection *connection, gpointer user_data) { WatchNameData *data = user_data; - GValue params[2] = { { 0, }, { 0, } }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; g_value_init (¶ms[0], G_TYPE_DBUS_CONNECTION); g_value_set_object (¶ms[0], connection); diff --git a/gio/gpollableinputstream.c b/gio/gpollableinputstream.c index 6bad2a0ce..199169db5 100644 --- a/gio/gpollableinputstream.c +++ b/gio/gpollableinputstream.c @@ -246,8 +246,8 @@ pollable_source_closure_callback (GObject *stream, { GClosure *closure = data; - GValue param = { 0, }; - GValue result_value = { 0, }; + GValue param = G_VALUE_INIT; + GValue result_value = G_VALUE_INIT; gboolean result; g_value_init (&result_value, G_TYPE_BOOLEAN); diff --git a/gio/gsettings.c b/gio/gsettings.c index cf1d23aed..4f6b2f41d 100644 --- a/gio/gsettings.c +++ b/gio/gsettings.c @@ -2522,7 +2522,7 @@ g_settings_binding_key_changed (GSettings *settings, gpointer user_data) { GSettingsBinding *binding = user_data; - GValue value = { 0, }; + GValue value = G_VALUE_INIT; GVariant *variant; g_assert (settings == binding->info.settings); @@ -2582,7 +2582,7 @@ g_settings_binding_property_changed (GObject *object, gpointer user_data) { GSettingsBinding *binding = user_data; - GValue value = { 0, }; + GValue value = G_VALUE_INIT; GVariant *variant; g_assert (object == binding->object); diff --git a/gio/gsocket.c b/gio/gsocket.c index c3c1ac6a0..8713ca950 100644 --- a/gio/gsocket.c +++ b/gio/gsocket.c @@ -2536,8 +2536,8 @@ socket_source_closure_callback (GSocket *socket, { GClosure *closure = data; - GValue params[2] = { { 0, }, { 0, } }; - GValue result_value = { 0, }; + GValue params[2] = { G_VALUE_INIT, G_VALUE_INIT }; + GValue result_value = G_VALUE_INIT; gboolean result; g_value_init (&result_value, G_TYPE_BOOLEAN);