From a4249b48ee452f1595adb916f5b57bc8b365962f Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 26 Feb 2017 00:56:13 -0500 Subject: [PATCH] Patched to compile on C89 compilers. --- src/audio/SDL_audio.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/audio/SDL_audio.c b/src/audio/SDL_audio.c index 0b7c6dd83..39d2a7087 100644 --- a/src/audio/SDL_audio.c +++ b/src/audio/SDL_audio.c @@ -687,8 +687,9 @@ SDL_RunAudio(void *devicep) SDL_AudioStreamPut(device->stream, data, data_len); while (SDL_AudioStreamAvailable(device->stream) >= ((int) device->spec.size)) { + int got; data = SDL_AtomicGet(&device->enabled) ? current_audio.impl.GetDeviceBuf(device) : NULL; - const int got = SDL_AudioStreamGet(device->stream, data ? data : device->work_buffer, device->spec.size); + got = SDL_AudioStreamGet(device->stream, data ? data : device->work_buffer, device->spec.size); SDL_assert((got < 0) || (got == device->spec.size)); if (data == NULL) { /* device is having issues... */