Skip to content

Commit 013eccd

Browse files
committed
Clean up
1 parent 2e9a7de commit 013eccd

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

.github/workflows/build.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ jobs:
1212
name: Build with ESP-IDF ${{ matrix.idf_ver }} for ${{ matrix.idf_target }}
1313
runs-on: ubuntu-latest
1414
strategy:
15-
fail-fast: false
1615
matrix:
1716
# The version names here correspond to the versions of espressif/idf Docker image.
1817
# See https://hub.docker.com/r/espressif/idf/tags and

src/NimBLERemoteCharacteristic.cpp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -103,18 +103,15 @@ bool NimBLERemoteCharacteristic::retrieveDescriptors(const NimBLEUUID* uuidFilte
103103
desc_filter_t filter = {uuidFilter, &taskData};
104104
const uint16_t handle = getHandle();
105105
const uint16_t svcHandle = getRemoteService()->getEndHandle();
106+
const uint16_t cltHandle = getClient()->getConnHandle();
106107

107-
// If this is the last handle then there are no descriptors
108+
// If this is the last handle then there are no more descriptors
108109
if (handle == svcHandle) {
109-
NIMBLE_LOGD(LOG_TAG, "<< retrieveDescriptors(): found 0 descriptors.");
110+
NIMBLE_LOGD(LOG_TAG, "<< retrieveDescriptors(): found %d descriptors.", m_vDescriptors.size());
110111
return true;
111112
}
112113

113-
int rc = ble_gattc_disc_all_dscs(getClient()->getConnHandle(),
114-
handle,
115-
svcHandle,
116-
NimBLERemoteCharacteristic::descriptorDiscCB,
117-
&filter);
114+
int rc = ble_gattc_disc_all_dscs(cltHandle, handle, svcHandle, descriptorDiscCB, &filter);
118115
if (rc != 0) {
119116
NIMBLE_LOGE(LOG_TAG, "ble_gattc_disc_all_dscs: rc=%d %s", rc, NimBLEUtils::returnCodeToString(rc));
120117
return false;

0 commit comments

Comments
 (0)