Skip to content

Commit 0f13d98

Browse files
committed
Fix panic when discovery doesn't send an ok message after a command
1 parent c756a0f commit 0f13d98

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

arduino/discovery/discovery.go

+1
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,7 @@ func (disc *PluggableDiscovery) jsonDecodeLoop(in io.Reader, outChan chan<- *dis
162162
// This is fine, we exit gracefully
163163
disc.statusMutex.Lock()
164164
disc.state = Dead
165+
disc.incomingMessagesError = err
165166
disc.statusMutex.Unlock()
166167
close(outChan)
167168
return

0 commit comments

Comments
 (0)