File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -514,8 +514,7 @@ class SecurityManager
514
514
* Some or all of bonding information may be stored in memory while in use. This will write
515
515
* bonding data to persistent storage. This will have no effect if no persistent storage is enabled.
516
516
*
517
- * @note You still need to call preserveBondingStateOnReset(true) before reset happens for data to be
518
- * loaded when it's read.
517
+ * @note This implicitly also calls preserveBondingStateOnReset(true) inside.
519
518
*
520
519
* @note Depending on the driver used to implement the storage solution used this may be a disruptive
521
520
* operation and may cause active connections to drop due to failed processing deadlines.
Original file line number Diff line number Diff line change @@ -49,6 +49,10 @@ ble_error_t SecurityManager::preserveBondingStateOnReset(bool enable)
49
49
50
50
ble_error_t SecurityManager::writeBondingStateToPersistentStorage ()
51
51
{
52
+ ble_error_t err = impl->preserveBondingStateOnReset (true );
53
+ if (err) {
54
+ return err;
55
+ }
52
56
return impl->writeBondingStateToPersistentStorage ();
53
57
}
54
58
You can’t perform that action at this time.
0 commit comments