diff options
author | Damon Chaplin <damon@ximian.com> | 2001-11-14 07:55:26 +0800 |
---|---|---|
committer | Damon Chaplin <damon@src.gnome.org> | 2001-11-14 07:55:26 +0800 |
commit | 7c6861ba11143038d33d6c57a8890775020f4610 (patch) | |
tree | 2af5200a3f9dda48bae97a5aac1864299ed23b52 /calendar/conduits | |
parent | 16cb05f315452b36990666ab57d22385ec098ff5 (diff) | |
download | gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar.gz gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar.bz2 gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar.lz gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar.xz gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.tar.zst gsoc2013-evolution-7c6861ba11143038d33d6c57a8890775020f4610.zip |
make the timezone default to UTC. Fixes bug #14362.
2001-11-13 Damon Chaplin <damon@ximian.com>
* gui/alarm-notify/config-data.c (ensure_inited):
* gui/calendar-config.c (config_read):
* conduits/todo/todo-conduit.c (get_default_timezone):
* conduits/calendar/calendar-conduit.c (get_default_timezone):
make the timezone default to UTC. Fixes bug #14362.
svn path=/trunk/; revision=14691
Diffstat (limited to 'calendar/conduits')
-rw-r--r-- | calendar/conduits/calendar/calendar-conduit.c | 10 | ||||
-rw-r--r-- | calendar/conduits/todo/todo-conduit.c | 10 |
2 files changed, 12 insertions, 8 deletions
diff --git a/calendar/conduits/calendar/calendar-conduit.c b/calendar/conduits/calendar/calendar-conduit.c index 552ba41e69..58b7a7020f 100644 --- a/calendar/conduits/calendar/calendar-conduit.c +++ b/calendar/conduits/calendar/calendar-conduit.c @@ -261,14 +261,16 @@ get_default_timezone (void) CORBA_exception_free (&ev); - location = bonobo_config_get_string (db, "/Calendar/Display/Timezone", NULL); - if (location == NULL) - goto cleanup; + location = bonobo_config_get_string_with_default (db, + "/Calendar/Display/Timezone", "UTC", NULL); + if (!location || !location[0]) { + g_free (location); + location = g_strdup ("UTC"); + } timezone = icaltimezone_get_builtin_timezone (location); g_free (location); - cleanup: bonobo_object_release_unref (db, NULL); return timezone; diff --git a/calendar/conduits/todo/todo-conduit.c b/calendar/conduits/todo/todo-conduit.c index 99da43b13f..4964860e22 100644 --- a/calendar/conduits/todo/todo-conduit.c +++ b/calendar/conduits/todo/todo-conduit.c @@ -265,14 +265,16 @@ get_default_timezone (void) CORBA_exception_free (&ev); - location = bonobo_config_get_string (db, "/Calendar/Display/Timezone", NULL); - if (location == NULL) - goto cleanup; + location = bonobo_config_get_string_with_default (db, + "/Calendar/Display/Timezone", "UTC", NULL); + if (!location || !location[0]) { + g_free (location); + location = g_strdup ("UTC"); + } timezone = icaltimezone_get_builtin_timezone (location); g_free (location); - cleanup: bonobo_object_release_unref (db, NULL); return timezone; |