handle better devices which do not support feature calls

This commit is contained in:
Daniel Pavel 2012-11-08 00:28:40 +02:00
parent 8db1ce97a8
commit b2db0706c6
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ class _FeaturesArray(object):
except _api._FeatureNotSupported:
self.supported = False
else:
count = _base.request(handle, self.device.number, _pack('!BB', index, 0x00))
count = None if index is None else _base.request(handle, self.device.number, _pack('!BB', index, 0x00))
if count is None:
self.supported = False
else: