Merge pull request #140 from swilson/master
Fix crash caused by incorrectly formatted (e.g. 1 byte) device reports.
This commit is contained in:
1 file changed
+2
@@ -147,6 +147,8 @@ uint8_t BLEScanner::parseReportByType(const uint8_t* scandata, uint8_t scanlen,
|
||||
uint8_t len = 0;
|
||||
uint8_t const* ptr = NULL;
|
||||
|
||||
if ( scanlen < 2 ) return 0;
|
||||
|
||||
// len (1+data), type, data
|
||||
while ( scanlen )
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user