video_replay: ignore non-rtp packets

which cause log spam otherwise, in particular RTCP packets

BUG=None

Change-Id: I73c2b17afb4f69102e25eb360699ea7d93bb8175
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/356100
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42643}
This commit is contained in:
Philipp Hancke 2024-07-08 12:50:33 -07:00 committed by WebRTC LUCI CQ
parent f6a804826c
commit bdfe6ae801

View File

@ -609,9 +609,13 @@ class RtpReplayer final {
packet.original_length - packet.length);
packet_buffer.MutableData()[0] &= ~0x20;
}
// Check that the packet is a RTP packet and is valid.
if (!IsRtpPacket({packet.data, packet.length})) {
continue;
}
RtpPacket header;
header.Parse(packet_buffer);
if (header.Timestamp() < start_timestamp ||
if (!header.Parse(packet_buffer) ||
header.Timestamp() < start_timestamp ||
header.Timestamp() > stop_timestamp) {
continue;
}