don't ping devices known to be offline

This commit is contained in:
Daniel Pavel 2013-07-12 22:07:58 +02:00
parent 994bb07bc4
commit 141a5c3dee
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ class PairedDevice(object):
@property
def protocol(self):
if self._protocol is None:
if self._protocol is None and self.online is not False:
self._protocol = _base.ping(self.receiver.handle, self.number)
# if the ping failed, the peripheral is (almost) certainly offline
self.online = self._protocol is not None