stream/mts/psi.go: removed trimPadding function as we don't need this anymore

This commit is contained in:
saxon 2019-01-29 22:09:17 +10:30
parent 7f8465f1ad
commit d49a8b8c6b
1 changed files with 0 additions and 8 deletions

View File

@ -341,14 +341,6 @@ func (p *PSIBytes) createDescriptor(tag int, data []byte) {
updateCrc((*p)[1:])
}
// TODO: make this safer. If no padding, does this index out of range ?
func (p *PSIBytes) trimPadding() []byte {
sectionLength := SyntaxSecLenFrom(*p)
paddingIdx := (4 + sectionLength)
o := (*p)[:paddingIdx]
return o
}
func (p *PSIBytes) setProgInfoLen(l int) {
// TODO: check if pmt first
(*p)[ProgramInfoLenIdx1] &= 0xff ^ ProgramInfoLenMask1