ffmpeg | branch: release/4.2 | Michael Niedermayer <[email protected]> | 
Fri May 20 00:50:33 2022 +0200| [ea9418debcf3673428e1daef4e9978ab0a663e8e] | 
committer: Michael Niedermayer

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 <[email protected]>
(cherry picked from commit 73c0fd27c5c53c42e5060fb3a0c1fc5708b6f670)
Signed-off-by: Michael Niedermayer <[email protected]>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ea9418debcf3673428e1daef4e9978ab0a663e8e
---

 libavformat/rtsp.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 859defa592..664272c0ac 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -932,6 +932,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;

_______________________________________________
ffmpeg-cvslog mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to