aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2012-04-06 22:35:48 +0300
committerMartin Storsjö <martin@martin.st>2012-04-08 15:51:32 +0300
commit62c3c8ca78ee2da7dc20c2d6371866266c82966d (patch)
tree7d75e86b68b5a074318d326e698cd1bbabfa1d30 /libavformat
parent58e1032d8fddab10fc2cae845aa84c5772d4cdca (diff)
downloadffmpeg-62c3c8ca78ee2da7dc20c2d6371866266c82966d.tar.gz
rtsp: Don't use uninitialized data if there are no streams
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/rtsp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 403f038875..9ee7a758e4 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1391,7 +1391,7 @@ int ff_rtsp_make_setup_request(AVFormatContext *s, const char *host, int port,
goto fail;
}
- if (reply->timeout > 0)
+ if (rt->nb_rtsp_streams && reply->timeout > 0)
rt->timeout = reply->timeout;
if (rt->server_type == RTSP_SERVER_REAL)