src/audio/SDL_audio.c
changeset 7038 7f22b9ba218f
parent 7011 82bbfbbc720e
child 7342 4828e86c6010
equal deleted inserted replaced
7037:3fedf1f25b94 7038:7f22b9ba218f
   189 }
   189 }
   190 
   190 
   191 static int
   191 static int
   192 SDL_AudioOpenDevice_Default(_THIS, const char *devname, int iscapture)
   192 SDL_AudioOpenDevice_Default(_THIS, const char *devname, int iscapture)
   193 {
   193 {
   194     return 0;
   194     return -1;
   195 }
   195 }
   196 
   196 
   197 static void
   197 static void
   198 SDL_AudioLockDevice_Default(SDL_AudioDevice * device)
   198 SDL_AudioLockDevice_Default(SDL_AudioDevice * device)
   199 {
   199 {
   938     /* force a device detection if we haven't done one yet. */
   938     /* force a device detection if we haven't done one yet. */
   939     if ( ((iscapture) && (current_audio.inputDevices == NULL)) ||
   939     if ( ((iscapture) && (current_audio.inputDevices == NULL)) ||
   940          ((!iscapture) && (current_audio.outputDevices == NULL)) )
   940          ((!iscapture) && (current_audio.outputDevices == NULL)) )
   941         SDL_GetNumAudioDevices(iscapture);
   941         SDL_GetNumAudioDevices(iscapture);
   942 
   942 
   943     if (!current_audio.impl.OpenDevice(device, devname, iscapture)) {
   943     if (current_audio.impl.OpenDevice(device, devname, iscapture) < 0) {
   944         close_audio_device(device);
   944         close_audio_device(device);
   945         return 0;
   945         return 0;
   946     }
   946     }
   947     device->opened = 1;
   947     device->opened = 1;
   948 
   948