Skip to content

Commit 1ca5016

Browse files
author
Matthew Fisher
committed
Merge pull request #3778 from kalbasit/issue_3772
fix(logger): gracefully handle a nil return from etcd watch
2 parents 34cce83 + e803109 commit 1ca5016

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

logger/main.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,10 @@ func main() {
6666

6767
for {
6868
select {
69-
case er := <-drainRespChan:
70-
drainChan <- er.Node.Value
69+
case dr := <-drainRespChan:
70+
if dr != nil && dr.Node != nil {
71+
drainChan <- dr.Node.Value
72+
}
7173
case <-signalChan:
7274
close(exitChan)
7375
stopChan <- true

0 commit comments

Comments
 (0)