diff options
author | Max Kellermann <max@duempel.org> | 2009-01-25 18:47:21 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2009-01-25 18:47:21 +0100 |
commit | a45922cd66cf8a7a03905c020e50ab01dc05cfa9 (patch) | |
tree | 2171f4d74886b9d049eafe14dc2b1ce72036c912 /src/locate.c | |
parent | 7960ad32fcfb1e17c24d3b26e53a1cdbc5ca0028 (diff) | |
download | mpd-a45922cd66cf8a7a03905c020e50ab01dc05cfa9.tar.gz mpd-a45922cd66cf8a7a03905c020e50ab01dc05cfa9.tar.xz mpd-a45922cd66cf8a7a03905c020e50ab01dc05cfa9.zip |
use g_free() instead of free()
On some platforms, g_free() must be used for memory allocated by
GLib. This patch intends to correct a lot of occurrences, but is
probably not complete.
Diffstat (limited to 'src/locate.c')
-rw-r--r-- | src/locate.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/locate.c b/src/locate.c index 18d265490..55dad41c3 100644 --- a/src/locate.c +++ b/src/locate.c @@ -68,7 +68,7 @@ locate_item_new(const char *type_string, const char *needle) struct locate_item *ret = g_new(struct locate_item, 1); if (!locate_item_init(ret, type_string, needle)) { - free(ret); + g_free(ret); ret = NULL; } @@ -134,8 +134,8 @@ locate_item_list_casefold(const struct locate_item_list *list) void locate_item_free(struct locate_item *item) { - free(item->needle); - free(item); + g_free(item->needle); + g_free(item); } static bool |