aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-10-11 17:05:04 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-10-11 17:08:33 +0200
commit229ccce6cca7748f53cb4b6a8d035ddce5ac6b72 (patch)
tree70eda5a9b5a03da2384d6da9ac0ee4eadb4b5078
parent4b20b21b8dabc74d676404dea94d43569a54a6b1 (diff)
downloadffmpeg-229ccce6cca7748f53cb4b6a8d035ddce5ac6b72.tar.gz
libxvid_rc: fix leaks in ff_xvid_rate_control_init()
Fixes CID733796 Part1 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/libxvid_rc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/libxvid_rc.c b/libavcodec/libxvid_rc.c
index 0f9e50e005..93aeb7199b 100644
--- a/libavcodec/libxvid_rc.c
+++ b/libavcodec/libxvid_rc.c
@@ -57,6 +57,8 @@ int ff_xvid_rate_control_init(MpegEncContext *s){
if (write(fd, tmp, strlen(tmp)) < 0) {
av_log(NULL, AV_LOG_ERROR, "Error %s writing 2pass logfile\n", strerror(errno));
+ av_free(tmp_name);
+ close(fd);
return AVERROR(errno);
}
}