Finish reformatting RTCPUtility::RTCPParserV2::Validate()
Half of the function's code was reformatted and reindented in https://codereview.webrtc.org/1307663004, but the bottom half was still adhering to an old coding style and using different indentation values. Not only does this make the code look confusing, but it can cause build issues on certain compilers: for example, GCC 6.2.0 with -Wall causes the build to fail because -Wmisleading-indentation is enabled. BUG=None R=asapersson@webrtc.org,danilchap@webrtc.org Review-Url: https://codereview.webrtc.org/2479193002 Cr-Commit-Position: refs/heads/master@{#14957}
This commit is contained in:
parent
3663c52382
commit
ec7b009752
@ -433,24 +433,22 @@ RTCPUtility::RTCPParserV2::Validate()
|
||||
_ptrRTCPDataEnd - _ptrRTCPDataBegin, &header))
|
||||
return; // NOT VALID!
|
||||
|
||||
// * if (!reducedSize) : first packet must be RR or SR.
|
||||
//
|
||||
// * The padding bit (P) should be zero for the first packet of a
|
||||
// compound RTCP packet because padding should only be applied,
|
||||
// if it is needed, to the last packet. (NOT CHECKED!)
|
||||
//
|
||||
// * The length fields of the individual RTCP packets must add up
|
||||
// to the overall length of the compound RTCP packet as
|
||||
// received. This is a fairly strong check. (NOT CHECKED!)
|
||||
// * if (!reducedSize) : first packet must be RR or SR.
|
||||
//
|
||||
// * The padding bit (P) should be zero for the first packet of a
|
||||
// compound RTCP packet because padding should only be applied,
|
||||
// if it is needed, to the last packet. (NOT CHECKED!)
|
||||
//
|
||||
// * The length fields of the individual RTCP packets must add up
|
||||
// to the overall length of the compound RTCP packet as
|
||||
// received. This is a fairly strong check. (NOT CHECKED!)
|
||||
|
||||
if (!_RTCPReducedSizeEnable)
|
||||
{
|
||||
if ((header.packet_type != PT_SR) && (header.packet_type != PT_RR)) {
|
||||
return; // NOT VALID
|
||||
}
|
||||
}
|
||||
if (!_RTCPReducedSizeEnable) {
|
||||
if ((header.packet_type != PT_SR) && (header.packet_type != PT_RR))
|
||||
return; // NOT VALID
|
||||
}
|
||||
|
||||
_validPacket = true;
|
||||
_validPacket = true;
|
||||
}
|
||||
|
||||
bool
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user