diff --git a/internal/server/state.go b/internal/server/state.go index 34db0b1..f4bb58c 100644 --- a/internal/server/state.go +++ b/internal/server/state.go @@ -90,7 +90,11 @@ func (sta *State) ParseConfig(conf string) (err error) { sta.LocalAPIRouter = manager.Router } - sta.Timeout = time.Duration(preParse.StreamTimeout) * time.Second + if preParse.StreamTimeout == 0 { + sta.Timeout = time.Duration(300) * time.Second + } else { + sta.Timeout = time.Duration(preParse.StreamTimeout) * time.Second + } redirAddr := preParse.RedirAddr colonSep := strings.Split(redirAddr, ":")