diff options
author | Scott Bauer <sbauer@plzdonthack.me> | 2017-10-11 23:23:47 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-10-11 23:23:47 +0000 |
commit | c7706eef3efbf21c169ae56eb94032034f719b17 (patch) | |
tree | 2ffc548ad1f18f56ef22ba02dee64c42a7615470 | |
parent | eb9ba9952350d9527d305fb615b4679d53370da0 (diff) | |
parent | 83aee7b3ba29e47fceffe0966d6f3f6240078c8e (diff) | |
download | android_system_bt-c7706eef3efbf21c169ae56eb94032034f719b17.tar.gz android_system_bt-c7706eef3efbf21c169ae56eb94032034f719b17.tar.bz2 android_system_bt-c7706eef3efbf21c169ae56eb94032034f719b17.zip |
Merge "Read the correct amount of attributes" into oc-dev
am: 83aee7b3ba
Change-Id: I633e4d7fbcb48387ca092e5e19a6f5c0ba015072
-rw-r--r-- | bta/gatt/bta_gattc_cache.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bta/gatt/bta_gattc_cache.cc b/bta/gatt/bta_gattc_cache.cc index e2244a1cf..adcb62d8c 100644 --- a/bta/gatt/bta_gattc_cache.cc +++ b/bta/gatt/bta_gattc_cache.cc @@ -1464,7 +1464,7 @@ bool bta_gattc_cache_load(tBTA_GATTC_CLCB* p_clcb) { attr = (tBTA_GATTC_NV_ATTR*)osi_malloc(sizeof(tBTA_GATTC_NV_ATTR) * num_attr); - if (fread(attr, sizeof(tBTA_GATTC_NV_ATTR), 0xFF, fd) != num_attr) { + if (fread(attr, sizeof(tBTA_GATTC_NV_ATTR), num_attr, fd) != num_attr) { APPL_TRACE_ERROR("%s: can't read GATT attributes: %s", __func__, fname); goto done; } |