From aa97ae7b1b2a8ac4cb8814b73a38fbe52a14a738 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sat, 2 Sep 2006 21:50:04 +0000 Subject: [PATCH] Fixed macosx audio initialization (passed wrong struct to CoreAudio). --- src/audio/macosx/SDL_coreaudio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/audio/macosx/SDL_coreaudio.c b/src/audio/macosx/SDL_coreaudio.c index 01414e5ba..ae87aeb65 100644 --- a/src/audio/macosx/SDL_coreaudio.c +++ b/src/audio/macosx/SDL_coreaudio.c @@ -195,7 +195,7 @@ Core_CloseAudio(_THIS) #define CHECK_RESULT(msg) \ if (result != noErr) { \ - SDL_SetError("Failed to start CoreAudio: " msg); \ + SDL_SetError("CoreAudio error (%s): %d", msg, (int) result); \ return -1; \ } @@ -281,7 +281,7 @@ Core_OpenAudio(_THIS, SDL_AudioSpec * spec) kAudioUnitProperty_StreamFormat, kAudioUnitScope_Input, 0, - &desc, sizeof (desc)); + &strdesc, sizeof (strdesc)); CHECK_RESULT("AudioUnitSetProperty (kAudioUnitProperty_StreamFormat)") /* Set the audio callback */ callback.inputProc = audioCallback;