()
| 453 | } |
| 454 | |
| 455 | func (b *StatisticsSummaryReportBlock) setupBlockHeader() { |
| 456 | b.XRHeader.BlockType = StatisticsSummaryReportBlockType |
| 457 | b.XRHeader.TypeSpecific = 0x00 |
| 458 | if b.LossReports { |
| 459 | b.XRHeader.TypeSpecific |= 0x80 |
| 460 | } |
| 461 | if b.DuplicateReports { |
| 462 | b.XRHeader.TypeSpecific |= 0x40 |
| 463 | } |
| 464 | if b.JitterReports { |
| 465 | b.XRHeader.TypeSpecific |= 0x20 |
| 466 | } |
| 467 | b.XRHeader.TypeSpecific |= TypeSpecificField((b.TTLorHopLimit & 0x03) << 3) |
| 468 | b.XRHeader.BlockLength = uint16(wireSize(b)/4 - 1) //nolint:gosec // G115 |
| 469 | } |
| 470 | |
| 471 | func (b *StatisticsSummaryReportBlock) unpackBlockHeader() { |
| 472 | b.LossReports = b.XRHeader.TypeSpecific&0x80 != 0 |
nothing calls this directly
no test coverage detected