diff options
author | Fabrice Bellard <fabrice@bellard.org> | 2002-05-18 23:11:09 +0000 |
---|---|---|
committer | Fabrice Bellard <fabrice@bellard.org> | 2002-05-18 23:11:09 +0000 |
commit | 1ea4f593658c8b161a0a725252058b49c16a6b29 (patch) | |
tree | 5bf96a2a7242b8a0c227a196a3368188a77f9d8e /libav/audio.c | |
parent | 065422677a17ddb3d84a3b85b5064eb7df7e2c8a (diff) | |
download | ffmpeg-1ea4f593658c8b161a0a725252058b49c16a6b29.tar.gz |
use av memory handling functions
Originally committed as revision 528 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libav/audio.c')
-rw-r--r-- | libav/audio.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libav/audio.c b/libav/audio.c index ddbe382d60..ab9e4757d2 100644 --- a/libav/audio.c +++ b/libav/audio.c @@ -161,7 +161,7 @@ static int audio_write_header(AVFormatContext *s1) s->channels = st->codec.channels; ret = audio_open(s, 1); if (ret < 0) { - free(s); + av_free(s); return -EIO; } else { return 0; @@ -201,7 +201,7 @@ static int audio_write_trailer(AVFormatContext *s1) AudioData *s = s1->priv_data; audio_close(s); - free(s); + av_free(s); return 0; } @@ -221,7 +221,7 @@ static int audio_read_header(AVFormatContext *s1, AVFormatParameters *ap) return -ENOMEM; st = av_mallocz(sizeof(AVStream)); if (!st) { - free(s); + av_free(s); return -ENOMEM; } s1->priv_data = s; @@ -232,8 +232,8 @@ static int audio_read_header(AVFormatContext *s1, AVFormatParameters *ap) ret = audio_open(s, 0); if (ret < 0) { - free(st); - free(s); + av_free(st); + av_free(s); return -EIO; } else { /* take real parameters */ @@ -284,7 +284,7 @@ static int audio_read_close(AVFormatContext *s1) AudioData *s = s1->priv_data; audio_close(s); - free(s); + av_free(s); return 0; } |