Check chan not closed before sending updates for memory loader (#1894)
* dont send on closed chan
This commit is contained in:
parent
07fef9fd33
commit
eee91ed976
@ -176,6 +176,11 @@ func (m *memory) update() {
|
|||||||
value: vals.Get(w.path...),
|
value: vals.Get(w.path...),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
select {
|
||||||
|
case <-w.exit:
|
||||||
|
continue
|
||||||
|
default:
|
||||||
|
}
|
||||||
select {
|
select {
|
||||||
case w.updates <- uv:
|
case w.updates <- uv:
|
||||||
default:
|
default:
|
||||||
|
Loading…
Reference in New Issue
Block a user