aboutsummaryrefslogtreecommitdiffstats
path: root/src/output/fifo_plugin.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-03 14:51:34 +0100
committerMax Kellermann <max@duempel.org>2009-01-03 14:51:34 +0100
commit2189796b96f94e93423a4f9931c7199d7da6dfa7 (patch)
tree294524c72231c2d36da917f888a1b0f2d84ab6b6 /src/output/fifo_plugin.c
parent3978b7b1eab754fe260820da649e342ed5691b14 (diff)
downloadmpd-2189796b96f94e93423a4f9931c7199d7da6dfa7.tar.gz
mpd-2189796b96f94e93423a4f9931c7199d7da6dfa7.tar.xz
mpd-2189796b96f94e93423a4f9931c7199d7da6dfa7.zip
null, fifo: use GLib instead of utils.h
Diffstat (limited to 'src/output/fifo_plugin.c')
-rw-r--r--src/output/fifo_plugin.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/output/fifo_plugin.c b/src/output/fifo_plugin.c
index b15f5288e..efadc8ff6 100644
--- a/src/output/fifo_plugin.c
+++ b/src/output/fifo_plugin.c
@@ -25,6 +25,9 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
+#include <errno.h>
+#include <string.h>
+#include <unistd.h>
#undef G_LOG_DOMAIN
#define G_LOG_DOMAIN "fifo"
@@ -43,26 +46,25 @@ static FifoData *newFifoData(void)
{
FifoData *ret;
- ret = xmalloc(sizeof(FifoData));
+ ret = g_new(FifoData, 1);
ret->path = NULL;
ret->input = -1;
ret->output = -1;
ret->created = 0;
ret->timer = NULL;
-
+
return ret;
}
static void freeFifoData(FifoData *fd)
{
- if (fd->path)
- free(fd->path);
+ g_free(fd->path);
if (fd->timer)
timer_free(fd->timer);
- free(fd);
+ g_free(fd);
}
static void removeFifo(FifoData *fd)