diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2009-11-19 19:46:17 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2009-11-19 19:46:17 +0000 |
commit | 258d5bdebe37486cf3a328131dca7ec392a9720e (patch) | |
tree | 9c30cd1f825346d9104ef265e95ea16ad6fcda10 /gps.py | |
parent | 37f91a9a9b6743caf23b25e972ccddce9af0de1a (diff) | |
download | gpsd-258d5bdebe37486cf3a328131dca7ec392a9720e.tar.gz |
Comment fix.
Diffstat (limited to 'gps.py')
-rwxr-xr-x | gps.py | 20 |
1 files changed, 11 insertions, 9 deletions
@@ -430,15 +430,17 @@ class gps(gpsdata): def waiting(self): "Return True if data is ready for the client." - # WARNING! When we're testing here is whether there's data left in - # sockfile.readline()'s read buffer before we look to see if - # there's input waiting at the socket level. The Python sockfile API - # doesn't expose a way to do this, so we have to rely on knowing - # that the read buffer is the _rbuf member and that it's a StringIO - # object. Without this test, we go back to having flaky regression - # errors at the end of check files, but with it the tests hang on some - # BSD-derived systems. This is OK for production use, because dropping - # some data on device close isn't actually a problem. + # WARNING! When we're testing here is whether there's data + # left in sockfile.readline()'s read buffer before we look to + # see if there's input waiting at the socket level. The Python + # sockfile API doesn't expose a way to do this, so we have to + # rely on knowing that the read buffer is the _rbuf member and + # that it's a StringIO object. Without this test, we go back + # to having flaky regression errors at the end of check files, + # but with it the tests hang on some BSD-derived systems. The + # former outcome () but not the latteris OK for production + # use, because dropping some data on device close isn't + # actually a problem. broken = ('openbsd4') if sys.platform not in broken and len(self.sockfile._rbuf.getvalue()) > 0: return True |