Hi!
This should imo not get applied if there are applications that allow larger
resolutions.
Please comment, Carl Eugen
diff --git a/libavformat/rtpenc_jpeg.c b/libavformat/rtpenc_jpeg.c
index 60629cf..c50f25f 100644
--- a/libavformat/rtpenc_jpeg.c
+++ b/libavformat/rtpenc_jpeg.c
@@ -41,6 +41,11 @@ void ff_rtp_send_jpeg(AVFormatContext *s1, const uint8_t
*buf, int size)
s->buf_ptr = s->buf;
s->timestamp = s->cur_timestamp;
+ if (s1->streams[0]->codec->width > 2040 || s1->streams[0]->codec->height >
2040) {
+ av_log(s1, AV_LOG_ERROR,
+ "RFC 2435 does not allow resolutions > 2040x2040\n");
+ return;
+ }
/* convert video pixel dimensions from pixels to blocks */
w = FF_CEIL_RSHIFT(s1->streams[0]->codec->width, 3);
h = FF_CEIL_RSHIFT(s1->streams[0]->codec->height, 3);
_______________________________________________
ffmpeg-devel mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel