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

Commit a00bde5a authored by Pavlin Radoslavov's avatar Pavlin Radoslavov
Browse files

Add missing data initialization

A local struct variable is not initialized (memset to 0)
when sending GET_REPORT_EVT to an application.
As a result, field hs_data.rsp_data.p_rpt_data might be used
uninitialized.

Bug: 22352578
Change-Id: I72141117187c392bc0502a17bf71859e67c8da54
parent 72bec73b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1897,6 +1897,7 @@ void bta_hh_le_proc_get_rpt_cmpl(tBTA_HH_DEV_CB *p_dev_cb, tBTA_GATTC_READ *p_da
        return;
    }

    memset(&hs_data, 0, sizeof(hs_data));
    hs_data.status  = BTA_HH_ERR;
    hs_data.handle  = p_dev_cb->hid_handle;