summaryrefslogtreecommitdiff
path: root/src/resources/sdlmusic.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/sdlmusic.cpp')
-rw-r--r--src/resources/sdlmusic.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/resources/sdlmusic.cpp b/src/resources/sdlmusic.cpp
index 5cadbd620..5f18d30d6 100644
--- a/src/resources/sdlmusic.cpp
+++ b/src/resources/sdlmusic.cpp
@@ -39,7 +39,11 @@ SDLMusic::~SDLMusic()
Resource *SDLMusic::load(SDL_RWops *const rw)
{
+#ifdef USE_SDL2
+ if (Mix_Music *const music = Mix_LoadMUS_RW(rw, 1))
+#else
if (Mix_Music *const music = Mix_LoadMUS_RW(rw))
+#endif
{
return new SDLMusic(music);
}