Skip to content

Commit

Permalink
gpio(core): fix sporadic hang on finish for discrete edge polling (#1107
Browse files Browse the repository at this point in the history
)
  • Loading branch information
gen2thomas authored Dec 11, 2024
1 parent 9dfcfc5 commit 29893b1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions system/digitalpin_poll.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ func startEdgePolling(
for {
select {
case <-quitChan:
if !firstLoopDone {
wg.Done()
}
return
default:
// note: pure reading takes between 30us and 1ms on rasperry Pi1, typically 50us, with sysfs also 500us
Expand Down

0 comments on commit 29893b1

Please sign in to comment.