|
@@ -334,6 +334,9 @@ static int sctp_write(URLContext *h, const uint8_t *buf, int size)
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (s->max_streams) {
|
|
if (s->max_streams) {
|
|
|
|
|
+ if (size < 2)
|
|
|
|
|
+ return AVERROR(EINVAL);
|
|
|
|
|
+
|
|
|
/*StreamId is introduced as a 2byte code into the stream*/
|
|
/*StreamId is introduced as a 2byte code into the stream*/
|
|
|
struct sctp_sndrcvinfo info = { 0 };
|
|
struct sctp_sndrcvinfo info = { 0 };
|
|
|
info.sinfo_stream = AV_RB16(buf);
|
|
info.sinfo_stream = AV_RB16(buf);
|