From 1ac63c2a9b6a725c4b3e4c4bac67a3ed9c5ba89c Mon Sep 17 00:00:00 2001
From: Stefan Gehrer <stefan.gehrer@gmx.de>
Date: Sat, 24 Jan 2009 08:20:42 +0000
Subject: [PATCH] return an error if we can not get a full packet, fixes hang
 on EOF

Originally committed as revision 16740 to svn://svn.ffmpeg.org/ffmpeg/trunk
---
 libavformat/iss.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/iss.c b/libavformat/iss.c
index c722f62d2bf..0d24c96ce3b 100644
--- a/libavformat/iss.c
+++ b/libavformat/iss.c
@@ -112,8 +112,8 @@ static int iss_read_packet(AVFormatContext *s, AVPacket *pkt)
     IssDemuxContext *iss = s->priv_data;
     int ret = av_get_packet(s->pb, pkt, iss->packet_size);
 
-    if(ret < 0)
-        return ret;
+    if(ret != iss->packet_size)
+        return AVERROR(EIO);
 
     pkt->stream_index = 0;
     pkt->pts = url_ftell(s->pb) - iss->sample_start_pos;
-- 
GitLab