mirror of
https://github.com/langhuihui/monibuca.git
synced 2026-05-07 21:01:13 +08:00
fix: crypto no idr frame
This commit is contained in:
@@ -157,8 +157,9 @@ func (t *Transform) Go() error {
|
||||
}
|
||||
}
|
||||
if needEncrypt {
|
||||
if encBytes, err := t.cryptor.Encrypt(mem); err == nil {
|
||||
copyVideo.Nalus.Append(encBytes)
|
||||
encBytes, err := t.cryptor.Encrypt(mem[2:])
|
||||
if err == nil {
|
||||
copyVideo.Nalus.Append(append([]byte{mem[0], mem[1]}, encBytes...))
|
||||
} else {
|
||||
copyVideo.Nalus.Append(mem)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user