diff options
author | Max Kellermann <max@duempel.org> | 2009-01-03 14:51:30 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2009-01-03 14:51:30 +0100 |
commit | 3978b7b1eab754fe260820da649e342ed5691b14 (patch) | |
tree | fd16dba91fe71a7f5a4880b786b7b7aadb0ce703 /src/song.c | |
parent | 2d6f4690913857201965a3a306ede5caca655e79 (diff) | |
download | mpd-3978b7b1eab754fe260820da649e342ed5691b14.tar.gz mpd-3978b7b1eab754fe260820da649e342ed5691b14.tar.xz mpd-3978b7b1eab754fe260820da649e342ed5691b14.zip |
song: use GLib instead of utils.h/log.h
Diffstat (limited to 'src/song.c')
-rw-r--r-- | src/song.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/song.c b/src/song.c index 4d93073a9..323262512 100644 --- a/src/song.c +++ b/src/song.c @@ -19,14 +19,14 @@ #include "song.h" #include "ls.h" #include "directory.h" -#include "utils.h" -#include "log.h" #include "mapper.h" #include "path.h" #include "playlist.h" #include "decoder_list.h" #include "decoder_api.h" +#include <glib.h> + #include <assert.h> #include <sys/types.h> #include <sys/stat.h> @@ -41,7 +41,7 @@ song_alloc(const char *url, struct directory *parent) assert(url); urllen = strlen(url); assert(urllen); - song = xmalloc(sizeof(*song) - sizeof(song->url) + urllen + 1); + song = g_malloc(sizeof(*song) - sizeof(song->url) + urllen + 1); song->tag = NULL; memcpy(song->url, url, urllen + 1); @@ -73,7 +73,7 @@ song_file_load(const char *path, struct directory *parent) assert((parent == NULL) == (*path == '/')); if (strchr(path, '\n')) { - DEBUG("newSong: '%s' is not a valid uri\n", path); + g_debug("newSong: '%s' is not a valid uri\n", path); return NULL; } @@ -98,7 +98,7 @@ song_free(struct song *song) { if (song->tag) tag_free(song->tag); - free(song); + g_free(song); } bool |