提交 b9c4980f authored 作者: Iñaki Baz Castillo's avatar Iñaki Baz Castillo

RTCP::ReceiverReportPacket::Parse(): Ensure there is space for the SSRC of the packet sender.

上级 597029a4
...@@ -72,7 +72,8 @@ namespace RTC ...@@ -72,7 +72,8 @@ namespace RTC
// Get the header. // Get the header.
auto* header = const_cast<CommonHeader*>(reinterpret_cast<const CommonHeader*>(data)); auto* header = const_cast<CommonHeader*>(reinterpret_cast<const CommonHeader*>(data));
if (sizeof(CommonHeader) > len) // Ensure there is space for the common header and the SSRC of packet sender.
if (sizeof(CommonHeader) + sizeof(uint32_t) > len)
{ {
MS_WARN_TAG(rtcp, "not enough space for receiver report packet, packet discarded"); MS_WARN_TAG(rtcp, "not enough space for receiver report packet, packet discarded");
......
Markdown 格式
0% 或
您添加了 0 人 到此讨论。请谨慎行事。
请先完成此评论的编辑!
请 注册 或者 后发表评论