mynewt-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ccoll...@apache.org
Subject [mynewt-newtmgr] 02/02: newtmgr - revendor
Date Thu, 24 Aug 2017 02:30:48 GMT
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

commit 89c71d46b5530341f1fefb2daf277d477bd4e610
Author: Christopher Collins <ccollins@apache.org>
AuthorDate: Wed Aug 23 19:29:22 2017 -0700

    newtmgr - revendor
---
 newtmgr/Godeps/Godeps.json                         | 56 +++++++++++-----------
 .../mynewt.apache.org/newtmgr/nmxact/nmble/conn.go | 11 +++--
 .../newtmgr/nmxact/nmble/listen.go                 |  5 +-
 3 files changed, 38 insertions(+), 34 deletions(-)

diff --git a/newtmgr/Godeps/Godeps.json b/newtmgr/Godeps/Godeps.json
index b94c1f2..69a7c15 100644
--- a/newtmgr/Godeps/Godeps.json
+++ b/newtmgr/Godeps/Godeps.json
@@ -127,73 +127,73 @@
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/adv",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/bledefs",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/mgmt",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/nmble",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/nmp",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/nmserial",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/nmxutil",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/oic",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/omp",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/scan",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/sesn",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/udp",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/xact",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		},
 		{
 			"ImportPath": "mynewt.apache.org/newtmgr/nmxact/xport",
-			"Comment": "mynewt_1_1_0_tag-72-g4bab771",
-			"Rev": "4bab771175fae622e2193415cb56fd4bf8008e0f"
+			"Comment": "mynewt_1_1_0_tag-75-g5ec2cea",
+			"Rev": "5ec2ceaf4415cd3777179e2899c90f1be5bd8226"
 		}
 	]
 }
diff --git a/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/conn.go b/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/conn.go
index e82b35e..f76907a 100644
--- a/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/conn.go
+++ b/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/conn.go
@@ -75,8 +75,9 @@ func (c *Conn) DisconnectChan() <-chan error {
 }
 
 func (c *Conn) abortNotifyListeners(err error) {
-	// No need to lock mutex; this should only be called after all go routines
-	// have terminated.
+	c.mtx.Lock()
+	defer c.mtx.Unlock()
+
 	for _, nl := range c.notifyMap {
 		nl.ErrChan <- err
 		close(nl.NotifyChan)
@@ -378,6 +379,7 @@ func (c *Conn) Connect(bx *BleXport, ownAddrType BleAddrType, peer BleDev,
 	return nil
 }
 
+// Opens the session for an already-established BLE connection.
 func (c *Conn) Inherit(connHandle uint16, bl *Listener) error {
 	if err := c.startConnecting(); err != nil {
 		return err
@@ -546,13 +548,14 @@ func (c *Conn) Profile() *Profile {
 	return &c.profile
 }
 
+// Indicates whether an error reported during MTU exchange is a "real" error or
+// not.  If the error was reported because MTU exchange already took place,
+// that isn't considered a real error.
 func isExchangeMtuError(err error) bool {
 	if err == nil {
 		return false
 	}
 
-	// If the operation failed because the peer already initiated the
-	// exchange, just pretend it was successful.
 	bhe := nmxutil.ToBleHost(err)
 	if bhe == nil {
 		return true
diff --git a/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/listen.go b/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/listen.go
index 19a1f2a..e1b35b6 100644
--- a/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/listen.go
+++ b/newtmgr/vendor/mynewt.apache.org/newtmgr/nmxact/nmble/listen.go
@@ -81,8 +81,9 @@ 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 bl.timer != nil {
-		bl.timer.Stop()
+	if t := bl.timer; t != nil {
+		nmxutil.StopAndDrainTimer(t)
+		bl.timer = nil
 	}
 
 	// 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" <commits@mynewt.apache.org>.

Mime
View raw message