Declare error.

This commit is contained in:
Alan Noble 2019-03-03 07:09:50 +00:00
parent c15c57f15f
commit 32280cb9d6
1 changed files with 2 additions and 1 deletions

View File

@ -308,7 +308,8 @@ func (s *rtmpSender) release() {
func (s *rtmpSender) restart() error { func (s *rtmpSender) restart() error {
s.conn.Close() s.conn.Close()
for n := 0; n < s.retries; n++ { var err error
for n := 0; n < s.retries; n++ {
s.conn, err = rtmp.Dial(s.url, s.timeout, s.log) s.conn, err = rtmp.Dial(s.url, s.timeout, s.log)
if err == nil { if err == nil {
break break