music_cmd.c
changeset 561 87bdb4c81c0b
parent 518 8bc9b5fd2aae
child 573 23d69b6621d0
     1.1 --- a/music_cmd.c	Fri Jan 13 02:39:41 2012 -0500
     1.2 +++ b/music_cmd.c	Fri Jan 13 03:15:19 2012 -0500
     1.3 @@ -48,7 +48,7 @@
     1.4  	MusicCMD *music;
     1.5  
     1.6  	/* Allocate and fill the music structure */
     1.7 -	music = (MusicCMD *)malloc(sizeof *music);
     1.8 +	music = (MusicCMD *)SDL_malloc(sizeof *music);
     1.9  	if ( music == NULL ) {
    1.10  		Mix_SetError("Out of memory");
    1.11  		return(NULL);
    1.12 @@ -123,7 +123,7 @@
    1.13  	if ( last_arg ) {
    1.14  		++argc;
    1.15  	}
    1.16 -	argv = (char **)malloc((argc+1)*(sizeof *argv));
    1.17 +	argv = (char **)SDL_malloc((argc+1)*(sizeof *argv));
    1.18  	if ( argv == NULL ) {
    1.19  		return(NULL);
    1.20  	}
    1.21 @@ -219,7 +219,7 @@
    1.22  /* Close the given music stream */
    1.23  void MusicCMD_FreeSong(MusicCMD *music)
    1.24  {
    1.25 -	free(music);
    1.26 +	SDL_free(music);
    1.27  }
    1.28  
    1.29  /* Return non-zero if a stream is currently playing */