mirror of
https://github.com/owncast/owncast.git
synced 2024-11-29 03:29:03 +03:00
Fix race condition where initial offline video state was not written
This commit is contained in:
parent
23ba9bb8be
commit
7556671afc
1 changed files with 9 additions and 9 deletions
|
@ -36,16 +36,16 @@ func (s *FileWriterReceiverService) SetupFileWriterReceiverService(callbacks Fil
|
|||
|
||||
localListenerAddress := "127.0.0.1:0"
|
||||
|
||||
// go func() {
|
||||
listener, err := net.Listen("tcp", localListenerAddress)
|
||||
if err != nil {
|
||||
log.Fatalln("Unable to start internal video writing service", err)
|
||||
}
|
||||
|
||||
listenerPort := strings.Split(listener.Addr().String(), ":")[1]
|
||||
config.InternalHLSListenerPort = listenerPort
|
||||
log.Traceln("Transcoder response service listening on: " + listenerPort)
|
||||
go func() {
|
||||
listener, err := net.Listen("tcp", localListenerAddress)
|
||||
if err != nil {
|
||||
log.Fatalln("Unable to start internal video writing service", err)
|
||||
}
|
||||
|
||||
listenerPort := strings.Split(listener.Addr().String(), ":")[1]
|
||||
config.InternalHLSListenerPort = listenerPort
|
||||
log.Traceln("Transcoder response service listening on: " + listenerPort)
|
||||
|
||||
if err := http.Serve(listener, httpServer); err != nil {
|
||||
log.Fatalln("Unable to start internal video writing service", err)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue