fix regression in le_handle_advertisement_report II

This commit is contained in:
matthias.ringwald@gmail.com 2015-02-16 20:40:07 +00:00
parent 03fbe9c621
commit a0aac9c4f8

View File

@ -729,6 +729,7 @@ void le_handle_advertisement_report(uint8_t *packet, int size){
uint8_t event[12 + LE_ADVERTISING_DATA_SIZE]; // use upper bound to avoid var size automatic var
for (i=0; i<num_reports;i++){
uint8_t data_length = packet[offset + 8];
uint8_t event_size = 10 + data_length;
int pos = 0;
event[pos++] = GAP_LE_ADVERTISING_REPORT;
event[pos++] = event_size;