summaryrefslogtreecommitdiff
path: root/libavformat/swfdec.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/swfdec.c')
-rw-r--r--libavformat/swfdec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/swfdec.c b/libavformat/swfdec.c
index 2d8e3b0e3e..20f1568e6f 100644
--- a/libavformat/swfdec.c
+++ b/libavformat/swfdec.c
@@ -119,10 +119,10 @@ retry:
z->avail_out = buf_size;
ret = inflate(z, Z_NO_FLUSH);
- if (ret < 0)
- return AVERROR(EINVAL);
if (ret == Z_STREAM_END)
return AVERROR_EOF;
+ if (ret != Z_OK)
+ return AVERROR(EINVAL);
if (buf_size - z->avail_out == 0)
goto retry;