[evolution/wip/gsettings: 19/29] NULL-terminate arrays that we pass to g_settings_set_strv
- From: Rodrigo Moya <rodrigo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/gsettings: 19/29] NULL-terminate arrays that we pass to g_settings_set_strv
- Date: Thu, 13 Oct 2011 16:23:40 +0000 (UTC)
commit c94f0cf7538bae7e740d58893a8bfcf7eca49c97
Author: Rodrigo Moya <rodrigo gnome-db org>
Date: Thu Oct 13 13:46:30 2011 +0200
NULL-terminate arrays that we pass to g_settings_set_strv
calendar/gui/alarm-notify/config-data.c | 1 +
calendar/gui/calendar-config.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/calendar/gui/alarm-notify/config-data.c b/calendar/gui/alarm-notify/config-data.c
index f44a832..3275c4d 100644
--- a/calendar/gui/alarm-notify/config-data.c
+++ b/calendar/gui/alarm-notify/config-data.c
@@ -348,6 +348,7 @@ config_data_save_blessed_program (const gchar *program)
g_array_append_val (array, list[i]);
g_array_append_val (array, program);
+ g_array_append_val (array, NULL);
g_settings_set_strv (calendar_settings, "notify-programs", (const gchar *const *) array->data);
g_strfreev (list);
diff --git a/calendar/gui/calendar-config.c b/calendar/gui/calendar-config.c
index 85c2e3e..15df692 100644
--- a/calendar/gui/calendar-config.c
+++ b/calendar/gui/calendar-config.c
@@ -368,6 +368,7 @@ calendar_config_set_day_second_zone (const gchar *location)
array = g_ptr_array_new ();
for (i = 0, l = lst; i < max_zones && l != NULL; i++, l = l->next)
g_ptr_array_add (array, l->data);
+ g_ptr_array_add (array, NULL);
g_settings_set_strv (config, "day-second-zones", (const gchar * const *) array->pdata);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]