diff --git a/chaturbate/channel_internal.go b/chaturbate/channel_internal.go index 14f22bc..1fcd595 100644 --- a/chaturbate/channel_internal.go +++ b/chaturbate/channel_internal.go @@ -215,7 +215,9 @@ func (w *Channel) mergeSegments() { <-time.After(1 * time.Second) continue } + w.bufferLock.Lock() buf, ok := w.buffer[w.bufferIndex] + w.bufferLock.Unlock() if !ok { segmentRetries++ <-time.After(time.Duration(segmentRetries) * time.Second) diff --git a/main.go b/main.go index 7a67ec6..6ce22e4 100644 --- a/main.go +++ b/main.go @@ -31,7 +31,7 @@ const logo = ` func main() { app := &cli.App{ Name: "chaturbate-dvr", - Version: "1.0.5", + Version: "1.0.6", Usage: "Records your favorite Chaturbate stream 😎🫵", Flags: []cli.Flag{ &cli.StringFlag{