message: Cleanup RemoteEstimatorProxy::IncomingPacket
  relax DCHECK and explain when it previous version could be hit.
  Use concise versions of the GetExtension functions.
  Reduce scope of the `lock_`
  Cr-Commit-Position: refs/heads/main@{#39246}
diff: @@ -88,28 +88,31 @@ void RemoteEstimatorProxy::IncomingPacket(const RtpPacketReceived& packet) {
  RTC_LOG(LS_WARNING) << "Arrival time not set.";
  return;
  }
  - MutexLock lock(&lock_);
  - send_periodic_feedback_ = packet.HasExtension<TransportSequenceNumber>();
  Packet internal_packet = {.arrival_time = packet.arrival_time(),
  .size = DataSize::Bytes(packet.size()),
  .ssrc = packet.Ssrc()};
  uint16_t seqnum;
  - absl::optional<FeedbackRequest> feedback_request;
  - if (!packet.GetExtension<TransportSequenceNumber>(&seqnum)) {
  - if (!packet.GetExtension<TransportSequenceNumberV2>(&seqnum,
  - &feedback_request)) {
  - RTC_DCHECK_NOTREACHED() << " Expected transport sequence number.";
  + if (packet.GetExtension<TransportSequenceNumber>(&seqnum) ||
  + packet.GetExtension<TransportSequenceNumberV2>(
  + &seqnum, &internal_packet.feedback_request)) {
  + internal_packet.transport_sequence_number = seqnum;
  + } else {
  + // This function expected to be called only for packets that have
  + // TransportSequenceNumber rtp header extension, however malformed RTP
  + // packet may contain unparsable TransportSequenceNumber.
  + RTC_DCHECK(packet.HasExtension<TransportSequenceNumber>() ||
  + packet.HasExtension<TransportSequenceNumberV2>())
  + << " Expected transport sequence number.";
  return;
  }
  - }
  - internal_packet.transport_sequence_number = seqnum;
  - internal_packet.feedback_request = feedback_request;
  - uint32_t send_time_24_bits;
  - if (packet.GetExtension<AbsoluteSendTime>(&send_time_24_bits)) {
  - internal_packet.absolute_send_time_24bits = send_time_24_bits;
  - }
  + internal_packet.absolute_send_time_24bits =
  + packet.GetExtension<AbsoluteSendTime>();
  +
  + MutexLock lock(&lock_);
  + send_periodic_feedback_ = packet.HasExtension<TransportSequenceNumber>();
  +
  IncomingPacket(internal_packet);
  }
  