Fix race condition where initial offline video state was not written
This commit is contained in:
parent
23ba9bb8be
commit
7556671afc
@ -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…
x
Reference in New Issue
Block a user