Skip to content

Commit

Permalink
check decodingState custom if nil, init it
Browse files Browse the repository at this point in the history
  • Loading branch information
jdvideo committed Jan 15, 2020
1 parent 2ce07e6 commit 1c2d715
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions reader.go
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,9 @@ func decodeLineOfMediaPlaylist(p *MediaPlaylist, wv *WV, state *decodingState, l

if v.SegmentTag() {
state.tagCustom = true
if state.custom == nil {
state.custom = make(map[string]CustomTag)
}
state.custom[v.TagName()] = t
} else {
p.Custom[v.TagName()] = t
Expand Down

0 comments on commit 1c2d715

Please sign in to comment.