diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-10-26 17:27:53 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-10-26 18:24:50 +0200 |
commit | 59eae884292d4f1ab49de1835616d46a4c1236a8 (patch) | |
tree | 9d829082f728189291ae1da1ecea8e1a63f09772 /tools/cws2fws.c | |
parent | adc61d68b02cf91b594400e502c7786da1e02e11 (diff) | |
download | ffmpeg-59eae884292d4f1ab49de1835616d46a4c1236a8.tar.gz |
cws2fws: check inflateInit return value
Fixes CID733722
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'tools/cws2fws.c')
-rw-r--r-- | tools/cws2fws.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/cws2fws.c b/tools/cws2fws.c index 74588c10a6..8dc285bfff 100644 --- a/tools/cws2fws.c +++ b/tools/cws2fws.c @@ -79,7 +79,10 @@ int main(int argc, char *argv[]) zstream.zalloc = NULL; zstream.zfree = NULL; zstream.opaque = NULL; - inflateInit(&zstream); + if (inflateInit(&zstream) != Z_OK) { + fprintf(stderr, "inflateInit failed\n"); + return 1; + } for (i = 0; i < comp_len - 8;) { int ret, len = read(fd_in, &buf_in, 1024); |