Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
arduino-esp32
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
arduino-esp32
Commits
5999b7ba
Unverified
Commit
5999b7ba
authored
Sep 30, 2020
by
crnchbng
Committed by
GitHub
Sep 30, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed double delete of characteristics (#3521)
parent
7b613c12
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
4 deletions
+1
-4
libraries/BLE/src/BLERemoteService.cpp
libraries/BLE/src/BLERemoteService.cpp
+1
-4
No files found.
libraries/BLE/src/BLERemoteService.cpp
View file @
5999b7ba
...
...
@@ -302,13 +302,10 @@ std::string BLERemoteService::getValue(BLEUUID characteristicUuid) {
* @return N/A.
*/
void
BLERemoteService
::
removeCharacteristics
()
{
for
(
auto
&
myPair
:
m_characteristicMap
)
{
delete
myPair
.
second
;
//m_characteristicMap.erase(myPair.first); // Should be no need to delete as it will be deleted by the clear
}
m_characteristicMap
.
clear
();
// Clear the map
for
(
auto
&
myPair
:
m_characteristicMapByHandle
)
{
delete
myPair
.
second
;
// delete the characteristics only once
}
m_characteristicMapByHandle
.
clear
();
// Clear the map
}
// removeCharacteristics
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment