Fix double slashes in RTMP URL
This commit is contained in:
parent
a114f426d4
commit
bbcf0ab1b1
1 changed files with 6 additions and 1 deletions
|
|
@ -454,7 +454,12 @@ func (a *api) start() error {
|
|||
host = "localhost"
|
||||
}
|
||||
|
||||
template := "rtmp://" + host + ":" + port + cfg.RTMP.App + "/{name}"
|
||||
template := "rtmp://" + host + ":" + port
|
||||
if cfg.RTMP.App != "/" {
|
||||
template += cfg.RTMP.App
|
||||
}
|
||||
template += "/{name}"
|
||||
|
||||
if len(cfg.RTMP.Token) != 0 {
|
||||
template += "?token=" + cfg.RTMP.Token
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue