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

RTC: Use fast parse TWCCID, ignore in packet parsing. 4.0.86

1. TWCC should not be passed from end to end.
2. Publisher TWCC information, should be ignore when pass to player
3. Player should regenerate its own TWCC.
This commit is contained in:
winlin 2021-03-24 12:29:17 +08:00
parent f5ff28d47a
commit 4c39cc7c2f
5 changed files with 23 additions and 9 deletions

View file

@ -1122,7 +1122,7 @@ srs_error_t SrsRtcPublishStream::on_rtp(char* data, int nb_data)
// 2. Server may send multiple duplicated NACK to client, and got more than one ARQ packet, which also fail SRTP.
// so, we must parse the header before SRTP unprotect(which may fail and drop packet).
uint16_t twcc_sn = 0;
if ((err = srs_rtp_fast_parse_twcc(data, nb_data, &extension_types_, twcc_sn)) == srs_success) {
if ((err = srs_rtp_fast_parse_twcc(data, nb_data, twcc_id_, twcc_sn)) == srs_success) {
if((err = on_twcc(twcc_sn)) != srs_success) {
return srs_error_wrap(err, "on twcc");
}