$OpenBSD: patch-src_audio_SDL_audio_c,v 1.16 2009/01/24 10:56:11 jakemsr Exp $ --- src/audio/SDL_audio.c.orig Sun Dec 30 20:47:59 2007 +++ src/audio/SDL_audio.c Thu Jan 22 20:40:14 2009 @@ -36,6 +36,9 @@ /* Available audio drivers */ static AudioBootStrap *bootstrap[] = { +#if SDL_AUDIO_DRIVER_SNDIO + &SNDIO_bootstrap, +#endif #if SDL_AUDIO_DRIVER_BSD &BSD_AUDIO_bootstrap, #endif @@ -532,7 +535,7 @@ int SDL_OpenAudio(SDL_AudioSpec *desired, SDL_AudioSpe return(-1); } if ( audio->convert.needed ) { - audio->convert.len = (int) ( ((double) desired->size) / + audio->convert.len = (int) ( ((double) audio->spec.size) / audio->convert.len_ratio ); audio->convert.buf =(Uint8 *)SDL_AllocAudioMem( audio->convert.len*audio->convert.len_mult);