mirror of
https://github.com/XTLS/Xray-core.git
synced 2024-11-04 14:13:03 +00:00
13 lines
302 B
Go
13 lines
302 B
Go
package observatory
|
|
|
|
func (o *Observer) UpdateStatus(result *OutboundStatus) {
|
|
o.statusLock.Lock()
|
|
defer o.statusLock.Unlock()
|
|
|
|
if location := o.findStatusLocationLockHolderOnly(result.OutboundTag); location != -1 {
|
|
o.status[location] = result
|
|
} else {
|
|
o.status = append(o.status, result)
|
|
}
|
|
}
|