fix: allocate memory for geoip struct of new server instance (#530)

This commit is contained in:
UUBulb 2024-12-02 20:52:10 +08:00 committed by GitHub
parent b128a0a5ed
commit 085fd4ac97
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -31,6 +31,7 @@ func loadServers() {
innerS := s
innerS.Host = &model.Host{}
innerS.State = &model.HostState{}
innerS.GeoIP = new(model.GeoIP)
innerS.TaskCloseLock = new(sync.Mutex)
ServerList[innerS.ID] = &innerS
ServerUUIDToID[innerS.UUID] = innerS.ID