aboutsummaryrefslogtreecommitdiffstats
path: root/src/compress.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-03 14:52:59 +0100
committerMax Kellermann <max@duempel.org>2009-01-03 14:52:59 +0100
commit457301d97b9041747c8c019ab1e108b883bc85cc (patch)
tree369962dc0aef0a127e865fa3b66f0c3990884a59 /src/compress.c
parentdec4e4ca85278c957e574e6ade6ff03fffd1ace6 (diff)
downloadmpd-457301d97b9041747c8c019ab1e108b883bc85cc.tar.gz
mpd-457301d97b9041747c8c019ab1e108b883bc85cc.tar.xz
mpd-457301d97b9041747c8c019ab1e108b883bc85cc.zip
compress: use GLib instead of utils.h
Diffstat (limited to 'src/compress.c')
-rw-r--r--src/compress.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/compress.c b/src/compress.c
index b561cb045..ccc7ccfc6 100644
--- a/src/compress.c
+++ b/src/compress.c
@@ -21,7 +21,8 @@
*/
#include "compress.h"
-#include "utils.h"
+
+#include <glib.h>
#include <stdint.h>
#include <string.h>
@@ -66,7 +67,7 @@ void CompressCfg(int show_mon, int anticlip, int target, int gainmax,
prefs.buckets = buckets;
/* Allocate the peak structure */
- peaks = xrealloc(peaks, sizeof(int)*prefs.buckets);
+ peaks = g_realloc(peaks, sizeof(int)*prefs.buckets);
if (prefs.buckets > lastsize)
memset(peaks + lastsize, 0, sizeof(int)*(prefs.buckets
@@ -165,8 +166,7 @@ void CompressFree(void)
}
#endif
- if (peaks)
- free(peaks);
+ g_free(peaks);
}
void CompressDo(void *data, unsigned int length)