aboutsummaryrefslogtreecommitdiffstats
path: root/src/ape.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2011-07-19 00:24:20 +0200
committerMax Kellermann <max@duempel.org>2011-07-19 00:24:20 +0200
commiteb2f413cf030a8c9ed51d8dc081e51e4afd287fb (patch)
tree47c1265e07af284e8a2ced6cb968b5359b754274 /src/ape.c
parente54748d3554d57f8320dff7390fa605bf23d7cd0 (diff)
parent736fd0e29326548152e91e4e3fb8c0ea9c1b50ac (diff)
downloadmpd-eb2f413cf030a8c9ed51d8dc081e51e4afd287fb.tar.gz
mpd-eb2f413cf030a8c9ed51d8dc081e51e4afd287fb.tar.xz
mpd-eb2f413cf030a8c9ed51d8dc081e51e4afd287fb.zip
Merge branch 'v0.16.x'
Conflicts: NEWS configure.ac
Diffstat (limited to 'src/ape.c')
-rw-r--r--src/ape.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ape.c b/src/ape.c
index 4a4eaf87a..6257fe6b3 100644
--- a/src/ape.c
+++ b/src/ape.c
@@ -60,8 +60,10 @@ ape_scan_internal(FILE *fp, tag_ape_callback_t callback, void *ctx)
assert(remaining > 10);
char *buffer = g_malloc(remaining);
- if (fread(buffer, 1, remaining, fp) != remaining)
+ if (fread(buffer, 1, remaining, fp) != remaining) {
+ g_free(buffer);
return false;
+ }
/* read tags */
unsigned n = GUINT32_FROM_LE(footer.count);