aboutsummaryrefslogtreecommitdiff
path: root/Host/nxt-gdb-server.py
diff options
context:
space:
mode:
authorTat-Chee Wan (USM)2011-03-23 08:09:14 +0800
committerTat-Chee Wan (USM)2011-03-23 08:09:14 +0800
commit1fe10665ea04f53f336676e88712391b7e5331da (patch)
treea64256245180869f147e1e66481c804baba4e373 /Host/nxt-gdb-server.py
parent260f2f561dcb016d553e45338b46c0490e2980aa (diff)
receive from nxt only when we actually sent something to it
Diffstat (limited to 'Host/nxt-gdb-server.py')
-rwxr-xr-xHost/nxt-gdb-server.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Host/nxt-gdb-server.py b/Host/nxt-gdb-server.py
index a72055f..4babdb9 100755
--- a/Host/nxt-gdb-server.py
+++ b/Host/nxt-gdb-server.py
@@ -152,7 +152,7 @@ class NXTGDBServer:
# Some pyusb are buggy, ignore some "errors".
if e.args != ('No error', ):
raise e
- if LIBUSB_RECEIVE_BLOCKING:
+ if s and LIBUSB_RECEIVE_BLOCKING:
data = self.reassemble (brick.sock)
else:
client.close ()