mirror of
https://github.com/langhuihui/monibuca.git
synced 2026-05-08 17:11:05 +08:00
fix: gb28181 update source ip,port when recover device
This commit is contained in:
@@ -44,7 +44,7 @@ type GB28181Plugin struct {
|
||||
m7s.Plugin
|
||||
AutoInvite bool `default:"true" desc:"自动邀请"`
|
||||
Serial string `default:"34020000002000000001" desc:"sip 服务 id"` //sip 服务器 id, 默认 34020000002000000001
|
||||
Realm string `default:"3402000000" desc:"sip 服务域"` //sip 服务器域,默认 3402000000
|
||||
Realm string `default:"3402000000" desc:"sip 服务域"` //sip 服务器域,默认 3402000000
|
||||
Username string
|
||||
Password string
|
||||
Sip SipConfig
|
||||
@@ -657,6 +657,9 @@ func (gb *GB28181Plugin) RecoverDevice(d *Device, req *sip.Request) {
|
||||
d.UpdateTime = time.Now()
|
||||
d.RegisterTime = time.Now()
|
||||
d.Online = true
|
||||
d.IP = hostname
|
||||
d.Port = port
|
||||
d.HostAddress = hostname + ":" + portStr
|
||||
|
||||
if gb.DB != nil {
|
||||
var existing Device
|
||||
|
||||
Reference in New Issue
Block a user