Skip to content

Commit

Permalink
The soundfont API functions are public and should always be available.
Browse files Browse the repository at this point in the history
This fixes bugs 3071 and 3088
  • Loading branch information
slouken committed Oct 14, 2017
1 parent 14c823b commit 81cb076
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
4 changes: 0 additions & 4 deletions mixer.c
Expand Up @@ -110,9 +110,7 @@ static const char **chunk_decoders = NULL;
static int num_decoders = 0;

/* Semicolon-separated SoundFont paths */
#ifdef MID_MUSIC
extern char* soundfont_paths;
#endif

int Mix_GetNumChunkDecoders(void)
{
Expand Down Expand Up @@ -249,12 +247,10 @@ void Mix_Quit()
Mix_QuitOgg();
}
#endif
#ifdef MID_MUSIC
if (soundfont_paths) {
SDL_free(soundfont_paths);
soundfont_paths = NULL;
}
#endif
initialized = 0;
}

Expand Down
6 changes: 0 additions & 6 deletions music.c
Expand Up @@ -151,9 +151,7 @@ static const char **music_decoders = NULL;
static int num_decoders = 0;

/* Semicolon-separated SoundFont paths */
#ifdef MID_MUSIC
char* soundfont_paths = NULL;
#endif

int Mix_GetNumMusicDecoders(void)
{
Expand Down Expand Up @@ -1601,7 +1599,6 @@ void close_music(void)

int Mix_SetSoundFonts(const char *paths)
{
#ifdef MID_MUSIC
if (soundfont_paths) {
SDL_free(soundfont_paths);
soundfont_paths = NULL;
Expand All @@ -1613,11 +1610,9 @@ int Mix_SetSoundFonts(const char *paths)
return 0;
}
}
#endif
return 1;
}

#ifdef MID_MUSIC
const char* Mix_GetSoundFonts(void)
{
const char* force = getenv("SDL_FORCE_SOUNDFONTS");
Expand Down Expand Up @@ -1665,4 +1660,3 @@ int Mix_EachSoundFont(int (*function)(const char*, void*), void *data)
else
return 0;
}
#endif

0 comments on commit 81cb076

Please sign in to comment.