Skip to content

Commit a0968de

Browse files
rossbergtjammer
authored andcommitted
Add fix for Raylib FLAC bug to enable_formats.patch
See https://github.com/raysan5/raylib/pull/5133/files
1 parent a8ef215 commit a0968de

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

src/c/enable_formats.patch

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,15 @@ diff --git a/vendor/raylib/src/config.h b/vendor/raylib/src/config.h
2222
#define SUPPORT_FILEFORMAT_XM 1
2323
#define SUPPORT_FILEFORMAT_MOD 1
2424

25+
diff --git a/vendor/raylib/src/raudio.c b/vendor/raylib/src/raudio.c
26+
--- a/vendor/raylib/src/raudio.c
27+
+++ b/vendor/raylib/src/raudio.c
28+
@@ -1757,7 +1757,7 @@
29+
else if (music.ctxType == MUSIC_AUDIO_QOA) qoaplay_close((qoaplay_desc *)music.ctxData);
30+
#endif
31+
#if defined(SUPPORT_FILEFORMAT_FLAC)
32+
- else if (music.ctxType == MUSIC_AUDIO_FLAC) drflac_free((drflac *)music.ctxData, NULL);
33+
+ else if (music.ctxType == MUSIC_AUDIO_FLAC) { drflac_close((drflac *)music.ctxData); drflac_free((drflac *)music.ctxData, NULL); } // Raylib fix #5133
34+
#endif
35+
#if defined(SUPPORT_FILEFORMAT_XM)
36+
else if (music.ctxType == MUSIC_MODULE_XM) jar_xm_free_context((jar_xm_context_t *)music.ctxData);

0 commit comments

Comments
 (0)