You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by cc...@apache.org on 2017/08/24 18:33:00 UTC
[mynewt-newtmgr] branch master updated: nmxact - Fix BLE race
condition.
This is an automated email from the ASF dual-hosted git repository.
ccollins pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newtmgr.git
The following commit(s) were added to refs/heads/master by this push:
new af9174d nmxact - Fix BLE race condition.
af9174d is described below
commit af9174ddd6525ac7fa65aac29f5b15b64d160b8a
Author: Christopher Collins <cc...@apache.org>
AuthorDate: Thu Aug 24 11:32:24 2017 -0700
nmxact - Fix BLE race condition.
---
nmxact/nmble/listen.go | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/nmxact/nmble/listen.go b/nmxact/nmble/listen.go
index e1b35b6..19a1f2a 100644
--- a/nmxact/nmble/listen.go
+++ b/nmxact/nmble/listen.go
@@ -81,9 +81,8 @@ func (bl *Listener) AfterTimeout(tmo time.Duration) <-chan time.Time {
func (bl *Listener) Close() {
// This provokes a race condition. The timer may get initialized at any
// time.
- if t := bl.timer; t != nil {
- nmxutil.StopAndDrainTimer(t)
- bl.timer = nil
+ if bl.timer != nil {
+ bl.timer.Stop()
}
// Mark the command as acked in case the race condition mentioned above
--
To stop receiving notification emails like this one, please contact
['"commits@mynewt.apache.org" <co...@mynewt.apache.org>'].