Commit fd76abb6 authored by Juliusz Chroboczek's avatar Juliusz Chroboczek

Send up actions synchronously.

parent c00a2199
...@@ -366,15 +366,12 @@ func (up *rtpUpTrack) AddLocal(local conn.DownTrack) error { ...@@ -366,15 +366,12 @@ func (up *rtpUpTrack) AddLocal(local conn.DownTrack) error {
} }
} }
up.local = append(up.local, local) up.local = append(up.local, local)
up.action(trackActionAdd, local)
// do this asynchronously, to avoid deadlocks when multiple
// clients call this simultaneously.
go up.action(trackActionAdd, local)
return nil return nil
} }
func (up *rtpUpTrack) RequestKeyframe() error { func (up *rtpUpTrack) RequestKeyframe() error {
go up.action(trackActionKeyframe, nil) up.action(trackActionKeyframe, nil)
return nil return nil
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment