1.1 --- a/src/audio/nas/SDL_nasaudio.c Mon Feb 06 17:28:04 2006 +0000
1.2 +++ b/src/audio/nas/SDL_nasaudio.c Tue Feb 07 06:59:48 2006 +0000
1.3 @@ -66,8 +66,8 @@
1.4
1.5 static void Audio_DeleteDevice(SDL_AudioDevice *device)
1.6 {
1.7 - free(device->hidden);
1.8 - free(device);
1.9 + SDL_free(device->hidden);
1.10 + SDL_free(device);
1.11 }
1.12
1.13 static SDL_AudioDevice *Audio_CreateDevice(int devindex)
1.14 @@ -75,20 +75,20 @@
1.15 SDL_AudioDevice *this;
1.16
1.17 /* Initialize all variables that we clean on shutdown */
1.18 - this = (SDL_AudioDevice *)malloc(sizeof(SDL_AudioDevice));
1.19 + this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice));
1.20 if ( this ) {
1.21 - memset(this, 0, (sizeof *this));
1.22 + SDL_memset(this, 0, (sizeof *this));
1.23 this->hidden = (struct SDL_PrivateAudioData *)
1.24 - malloc((sizeof *this->hidden));
1.25 + SDL_malloc((sizeof *this->hidden));
1.26 }
1.27 if ( (this == NULL) || (this->hidden == NULL) ) {
1.28 SDL_OutOfMemory();
1.29 if ( this ) {
1.30 - free(this);
1.31 + SDL_free(this);
1.32 }
1.33 return(0);
1.34 }
1.35 - memset(this->hidden, 0, (sizeof *this->hidden));
1.36 + SDL_memset(this->hidden, 0, (sizeof *this->hidden));
1.37
1.38 /* Set the function pointers */
1.39 this->OpenAudio = NAS_OpenAudio;
1.40 @@ -293,7 +293,7 @@
1.41 if ( this->hidden->mixbuf == NULL ) {
1.42 return(-1);
1.43 }
1.44 - memset(this->hidden->mixbuf, spec->silence, spec->size);
1.45 + SDL_memset(this->hidden->mixbuf, spec->silence, spec->size);
1.46
1.47 /* Get the parent process id (we're the parent of the audio thread) */
1.48 this->hidden->parent = getpid();