Skip to content

Commit

Permalink
test/simplesdl: Use SDL_malloc/SDL_free instead of malloc/free.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Aug 26, 2016
1 parent 482c9d5 commit 5b9e039
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/simplesdl.c
Expand Up @@ -67,7 +67,7 @@ static void SDLCALL audio_callback(void *userdata, Uint8 *stream, int len)
if (item->offset >= item->audio->frames)
{
THEORAPLAY_freeAudio(item->audio);
free((void *) item);
SDL_free((void *) item);
audio_queue = next;
} // if
} // while
Expand All @@ -82,7 +82,7 @@ static void SDLCALL audio_callback(void *userdata, Uint8 *stream, int len)

static void queue_audio(const THEORAPLAY_AudioPacket *audio)
{
AudioQueue *item = (AudioQueue *) malloc(sizeof (AudioQueue));
AudioQueue *item = (AudioQueue *) SDL_malloc(sizeof (AudioQueue));
if (!item)
{
THEORAPLAY_freeAudio(audio);
Expand Down

0 comments on commit 5b9e039

Please sign in to comment.