blob: 5f58a5f8176ed583183ec5326f52852ffe586e42 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
From be3c8154ff9dc309caf41afe917b001e887e2e3e Mon Sep 17 00:00:00 2001
From: Christoph Mende <mende.christoph@gmail.com>
Date: Wed, 10 Apr 2013 10:53:02 +0000
Subject: [PATCH] decoder/mikmod: use MikMod_free() to free the title
Player_LoadTitle() returns an aligned pointer that cannot be freed with
free(). The correct way to free the pointer is MikMod_free() which
extracts the original pointer from the buffer.
Signed-off-by: Christoph Mende <mende.christoph@gmail.com>
---
src/decoder/mikmod_decoder_plugin.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/decoder/mikmod_decoder_plugin.c b/src/decoder/mikmod_decoder_plugin.c
index 5681a7a..5b5a1c6 100644
--- a/src/decoder/mikmod_decoder_plugin.c
+++ b/src/decoder/mikmod_decoder_plugin.c
@@ -200,7 +200,7 @@ mikmod_decoder_scan_file(const char *path_fs,
if (title != NULL) {
tag_handler_invoke_tag(handler, handler_ctx,
TAG_TITLE, title);
- free(title);
+ MikMod_free(title);
}
return true;
--
1.8.1.2
|