Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9c98d4bc authored by Myles Watson's avatar Myles Watson Committed by Andre Eisenbach
Browse files

btm: Restrict EXTENDED_INQUIRY_RESULT to 1 result



The spec only allows one result per event.
Abort processing and return if the spec is not followed.

Bug: 29141745
Change-Id: Ic414b28adadec274779b0d953d12d499a619aff6
Signed-off-by: default avatarMyles Watson <mylesgw@google.com>
parent c0811609
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1874,6 +1874,12 @@ void btm_process_inq_results (UINT8 *p, UINT8 inq_res_mode)

    STREAM_TO_UINT8 (num_resp, p);

    if (inq_res_mode == BTM_INQ_RESULT_EXTENDED && (num_resp > 1)) {
        BTM_TRACE_ERROR ("btm_process_inq_results() extended results (%d) > 1",
                         num_resp);
        return;
    }

    for (xx = 0; xx < num_resp; xx++)
    {
        update = FALSE;