mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-02-12 23:03:37 +00:00
audio: Moved a variable into nested scope where it's actually used.
This commit is contained in:
@@ -2464,11 +2464,9 @@ void SDL_DefaultAudioDeviceChanged(SDL_AudioDevice *new_default_device)
|
||||
|
||||
SDL_SetAudioPostmixCallback(logdev->instance_id, logdev->postmix, logdev->postmix_userdata);
|
||||
|
||||
SDL_PendingAudioDeviceEvent *p;
|
||||
|
||||
// Queue an event for each logical device we moved.
|
||||
if (spec_changed) {
|
||||
p = (SDL_PendingAudioDeviceEvent *)SDL_malloc(sizeof(SDL_PendingAudioDeviceEvent));
|
||||
SDL_PendingAudioDeviceEvent *p = (SDL_PendingAudioDeviceEvent *)SDL_malloc(sizeof(SDL_PendingAudioDeviceEvent));
|
||||
if (p) { // if this failed, no event for you, but you have deeper problems anyhow.
|
||||
p->type = SDL_EVENT_AUDIO_DEVICE_FORMAT_CHANGED;
|
||||
p->devid = logdev->instance_id;
|
||||
|
||||
Reference in New Issue
Block a user