diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2013-09-05 13:01:07 -0500 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2013-09-05 13:01:07 -0500 |
commit | fdd57db6d6a81951da34675ee89e6e0f1b77b59e (patch) | |
tree | bf737851dc78bc800ada644baa9861c6df47783b | |
parent | d79408477c6fae230193f11be058c564f230ab8f (diff) | |
download | ayatana-indicator-datetime-fdd57db6d6a81951da34675ee89e6e0f1b77b59e.tar.gz ayatana-indicator-datetime-fdd57db6d6a81951da34675ee89e6e0f1b77b59e.tar.bz2 ayatana-indicator-datetime-fdd57db6d6a81951da34675ee89e6e0f1b77b59e.zip |
use GSlice for allocating/freeing service's TimeLocation structs
-rw-r--r-- | src/service.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/service.c b/src/service.c index 4c51e31..c36e996 100644 --- a/src/service.c +++ b/src/service.c @@ -908,7 +908,7 @@ time_location_free (struct TimeLocation * loc) g_date_time_unref (loc->local_time); g_free (loc->name); g_free (loc->zone); - g_free (loc); + g_slice_free (struct TimeLocation, loc); } static struct TimeLocation* @@ -916,7 +916,7 @@ time_location_new (const char * zone, const char * name, gboolean visible) { - struct TimeLocation * loc = g_new (struct TimeLocation, 1); + struct TimeLocation * loc = g_slice_new (struct TimeLocation); GTimeZone * tz = g_time_zone_new (zone); loc->zone = g_strdup (zone); loc->name = g_strdup (name); |