[fix] fix crash due to unsupported bitrate limits

This commit is contained in:
dijunkun
2025-03-28 17:37:35 +08:00
parent 506ded3027
commit 794d57eb40
13 changed files with 132 additions and 126 deletions

View File

@@ -38,11 +38,14 @@ class PacketSenderImp : public PacketSender,
public:
int Send() override { return 0; }
int EnqueueRtpPacket(std::vector<std::unique_ptr<RtpPacket>>& rtp_packets,
int64_t captured_timestamp_us) override;
int EnqueueRtpPackets(std::vector<std::unique_ptr<RtpPacket>>& rtp_packets,
int64_t captured_timestamp_us) override;
int EnqueueRtpPacket(std::vector<std::unique_ptr<webrtc::RtpPacketToSend>>&
rtp_packets) override;
int EnqueueRtpPackets(std::vector<std::unique_ptr<webrtc::RtpPacketToSend>>&
rtp_packets) override;
int EnqueueRtpPacket(
std::unique_ptr<webrtc::RtpPacketToSend> rtp_packet) override;
public:
void SetOnSentPacketFunc(
@@ -109,6 +112,7 @@ class PacketSenderImp : public PacketSender,
// PacingController::PacketSenderImp::SendPacket() when it's time to send.
void EnqueuePackets(
std::vector<std::unique_ptr<webrtc::RtpPacketToSend>> packets);
void EnqueuePacket(std::unique_ptr<webrtc::RtpPacketToSend> packet);
// Remove any pending packets matching this SSRC from the packet queue.
void RemovePacketsForSsrc(uint32_t ssrc);