Skip to content

Commit

Permalink
fix: clear partialMsg
Browse files Browse the repository at this point in the history
  • Loading branch information
tonygilkerson committed Mar 21, 2024
1 parent 1236fda commit 688728f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/serial/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,9 @@ func serialServer(port *serial.Port) {
partialMsg = messages
log.Printf("serialServer: no terminator found, this is a partial message, set partialMsg and continue: %v",partialMsg)
continue
} else {
log.Printf("serialServer: found terminator, clear partialMsg\n")
partialMsg = ""
}

log.Printf("serialServer: messages that need split: %v",messages)
Expand Down

0 comments on commit 688728f

Please sign in to comment.