go2rtc icon indicating copy to clipboard operation
go2rtc copied to clipboard

Panic on h264.EmitNalus

Open AlexxIT opened this issue 1 year ago • 0 comments

panic: runtime error: index out of range [3] with length 2

goroutine 849 [running]:
encoding/binary.bigEndian.Uint32(...)
	encoding/binary/binary.go:157
github.com/AlexxIT/go2rtc/pkg/h264.EmitNalus({0xa3cc000, 0x186f8, 0x186f8}, 0x1, 0xee1bec0)
	github.com/AlexxIT/go2rtc/pkg/h264/payloader.go:70 +0x114
github.com/AlexxIT/go2rtc/pkg/h264.(*Payloader).Payload(0x3944810, 0x4a4, {0xa3cc000, 0x186f8, 0x186f8})
	github.com/AlexxIT/go2rtc/pkg/h264/payloader.go:87 +0xa8
github.com/AlexxIT/go2rtc/pkg/h264.RTPPay.func1(0x88b4e60)
	github.com/AlexxIT/go2rtc/pkg/h264/rtp.go:119 +0x68
github.com/AlexxIT/go2rtc/pkg/h264.RepairAVCC.func1(0x88b4e60)
	github.com/AlexxIT/go2rtc/pkg/h264/avcc.go:22 +0x14c
github.com/AlexxIT/go2rtc/pkg/core.(*Sender).HandleRTP.func1()
	github.com/AlexxIT/go2rtc/pkg/core/track.go:144 +0x64
created by github.com/AlexxIT/go2rtc/pkg/core.(*Sender).HandleRTP in goroutine 843
	github.com/AlexxIT/go2rtc/pkg/core/track.go:140 +0x5dc

https://github.com/AlexxIT/go2rtc/issues/1075

AlexxIT avatar May 01 '24 09:05 AlexxIT