rtsp: Make sure the ret variable is initialized in ff_rtsp_fetch_packet
authorMartin Storsjö <martin@martin.st>
Wed, 17 Oct 2012 13:46:29 +0000 (16:46 +0300)
committerMartin Storsjö <martin@martin.st>
Fri, 19 Oct 2012 22:59:06 +0000 (01:59 +0300)
Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/rtsp.c

index 160c0f7..bbe08e6 100644 (file)
@@ -1808,7 +1808,8 @@ int ff_rtsp_fetch_packet(AVFormatContext *s, AVPacket *pkt)
                 rt->recvbuf_pos += ret;
                 ret = rt->recvbuf_pos < rt->recvbuf_len;
             }
-        }
+        } else
+            ret = -1;
         if (ret == 0) {
             rt->cur_transport_priv = NULL;
             return 0;