src/audio/SDL_audio.c
changeset 9401 529007547fb6
parent 9399 a684dbd185c7
child 9404 f48039db971c
     1.1 --- a/src/audio/SDL_audio.c	Thu Mar 19 22:08:12 2015 -0400
     1.2 +++ b/src/audio/SDL_audio.c	Thu Mar 19 22:11:20 2015 -0400
     1.3 @@ -351,6 +351,7 @@
     1.4          /* Post the event, if desired */
     1.5          if (SDL_GetEventState(SDL_AUDIODEVICEADDED) == SDL_ENABLE) {
     1.6              SDL_Event event;
     1.7 +            SDL_zero(event);
     1.8              event.adevice.type = SDL_AUDIODEVICEADDED;
     1.9              event.adevice.which = device_index;
    1.10              event.adevice.iscapture = iscapture;
    1.11 @@ -377,6 +378,7 @@
    1.12      /* Post the event, if desired */
    1.13      if (SDL_GetEventState(SDL_AUDIODEVICEREMOVED) == SDL_ENABLE) {
    1.14          SDL_Event event;
    1.15 +        SDL_zero(event);
    1.16          event.adevice.type = SDL_AUDIODEVICEREMOVED;
    1.17          event.adevice.which = device->id;
    1.18          event.adevice.iscapture = device->iscapture ? 1 : 0;