diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2022-05-20 00:50:33 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2022-10-09 22:15:40 +0200 |
commit | 6c1a7a829d5c1dc57f0411c7116effc5e8e6b1f2 (patch) | |
tree | f375ddf69575866a1a88b4c1cd09c157a8aaab62 | |
parent | 8a4e3bc1c5c62df3434573adfd254cc68c826f7e (diff) | |
download | ffmpeg-6c1a7a829d5c1dc57f0411c7116effc5e8e6b1f2.tar.gz |
avformat/rtsp: break on unknown protocols
This function needs more cleanup and it lacks error handling
Fixes: use of uninitialized memory
Fixes: CID700776
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 73c0fd27c5c53c42e5060fb3a0c1fc5708b6f670)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavformat/rtsp.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c index 975637cf54..7e0a20e7d8 100644 --- a/libavformat/rtsp.c +++ b/libavformat/rtsp.c @@ -928,6 +928,8 @@ static void rtsp_parse_transport(AVFormatContext *s, ";,", &p); } th->transport = RTSP_TRANSPORT_RAW; + } else { + break; } if (!av_strcasecmp(lower_transport, "TCP")) th->lower_transport = RTSP_LOWER_TRANSPORT_TCP; |