internal/clientinfo: make SetSelfIP to update new data

So after network changes, the new data will be used instead of the stale
old one.
This commit is contained in:
Cuong Manh Le
2025-02-07 14:25:18 +07:00
committed by Cuong Manh Le
parent 0c74838740
commit 715bcc4aa1

View File

@@ -173,6 +173,8 @@ func (t *Table) SetSelfIP(ip string) {
t.selfIPLock.Lock()
defer t.selfIPLock.Unlock()
t.selfIP = ip
t.dhcp.selfIP = t.selfIP
t.dhcp.addSelf()
}
func (t *Table) init() {