[FFmpeg-cvslog] libavformat/rtpdec_rfc4175: Check for zero pgroup before mod

Kyle Schwarz git at videolan.org
Tue Jul 6 17:38:40 EEST 2021


ffmpeg | branch: master | Kyle Schwarz <zeranoe at gmail.com> | Sat Jun 26 21:10:43 2021 -0400| [a61d1909729caa9c04cecb3a28efd71bc7f433f8] | committer: Lynne

libavformat/rtpdec_rfc4175: Check for zero pgroup before mod

Signed-off-by: Kyle Schwarz <zeranoe at gmail.com>

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

 libavformat/rtpdec_rfc4175.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/rtpdec_rfc4175.c b/libavformat/rtpdec_rfc4175.c
index e9c62c1389..4daff4da5a 100644
--- a/libavformat/rtpdec_rfc4175.c
+++ b/libavformat/rtpdec_rfc4175.c
@@ -199,7 +199,7 @@ static int rfc4175_handle_packet(AVFormatContext *ctx, PayloadContext *data,
         cont = headers[4] & 0x80;
         headers += 6;
 
-        if (length % data->pgroup)
+        if (!data->pgroup || length % data->pgroup)
             return AVERROR_INVALIDDATA;
 
         if (length > payload_len)



More information about the ffmpeg-cvslog mailing list