fix: allocate memory for geoip struct of new server instance (#530)
This commit is contained in:
parent
b128a0a5ed
commit
085fd4ac97
@ -31,6 +31,7 @@ func loadServers() {
|
|||||||
innerS := s
|
innerS := s
|
||||||
innerS.Host = &model.Host{}
|
innerS.Host = &model.Host{}
|
||||||
innerS.State = &model.HostState{}
|
innerS.State = &model.HostState{}
|
||||||
|
innerS.GeoIP = new(model.GeoIP)
|
||||||
innerS.TaskCloseLock = new(sync.Mutex)
|
innerS.TaskCloseLock = new(sync.Mutex)
|
||||||
ServerList[innerS.ID] = &innerS
|
ServerList[innerS.ID] = &innerS
|
||||||
ServerUUIDToID[innerS.UUID] = innerS.ID
|
ServerUUIDToID[innerS.UUID] = innerS.ID
|
||||||
|
Loading…
Reference in New Issue
Block a user