1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Squash: Merge SRS 4.0

This commit is contained in:
winlin 2021-09-26 17:12:55 +08:00
parent dc778020fc
commit 7d3ec991e1
3 changed files with 17 additions and 12 deletions

View file

@ -1715,19 +1715,19 @@ bool SrsRtmpFromRtcBridger::check_frame_complete(const uint16_t start, const uin
for (uint16_t i = 0; i < cnt; ++i) {
int index = cache_index((start + i));
SrsRtpPacket* pkt = cache_video_pkts_[index].pkt;
if (!pkt) {
// fix crash when pkt->payload() if pkt is nullptr;
continue;
}
SrsRtpFUAPayload2* fua_payload = dynamic_cast<SrsRtpFUAPayload2*>(pkt->payload());
if (fua_payload) {
if (fua_payload->start) {
++fu_s_c;
}
if (fua_payload->end) {
++fu_e_c;
}
// fix crash when pkt->payload() if pkt is nullptr;
if (!pkt) continue;
SrsRtpFUAPayload2* fua_payload = dynamic_cast<SrsRtpFUAPayload2*>(pkt->payload());
if (!fua_payload) continue;
if (fua_payload->start) {
++fu_s_c;
}
if (fua_payload->end) {
++fu_e_c;
}
}