Skip to content

Commit

Permalink
Static analysis fix: Removed unused variable.
Browse files Browse the repository at this point in the history
(We don't care if closing the device fails anyhow).
  • Loading branch information
icculus committed Mar 20, 2014
1 parent 3aae0ed commit a43dbfa
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/audio/coreaudio/SDL_coreaudio.c
Expand Up @@ -319,7 +319,6 @@ COREAUDIO_CloseDevice(_THIS)
{
if (this->hidden != NULL) {
if (this->hidden->audioUnitOpened) {
OSStatus result = noErr;
AURenderCallbackStruct callback;
const AudioUnitElement output_bus = 0;
const AudioUnitElement input_bus = 1;
Expand All @@ -331,14 +330,13 @@ COREAUDIO_CloseDevice(_THIS)
kAudioUnitScope_Input);

/* stop processing the audio unit */
result = AudioOutputUnitStop(this->hidden->audioUnit);
AudioOutputUnitStop(this->hidden->audioUnit);

/* Remove the input callback */
SDL_memset(&callback, 0, sizeof(AURenderCallbackStruct));
result = AudioUnitSetProperty(this->hidden->audioUnit,
kAudioUnitProperty_SetRenderCallback,
scope, bus, &callback,
sizeof(callback));
AudioUnitSetProperty(this->hidden->audioUnit,
kAudioUnitProperty_SetRenderCallback,
scope, bus, &callback, sizeof(callback));

#if MACOSX_COREAUDIO
CloseComponent(this->hidden->audioUnit);
Expand Down

0 comments on commit a43dbfa

Please sign in to comment.