Skip to content

Commit 5ae59fc

Browse files
committed
BLE - Improve FEATURE_PRIVACY conditions.
1 parent 24f7f36 commit 5ae59fc

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

features/FEATURE_BLE/source/generic/GenericSecurityManager.tpp

Lines changed: 4 additions & 0 deletions
Original file line numberOriginal file lineDiff line numberDiff line change
@@ -98,7 +98,9 @@ ble_error_t GenericSecurityManager<TPalSecurityManager, SigningMonitor>::init_(
98
#endif
98
#endif
99
_pal.set_event_handler(this);
99
_pal.set_event_handler(this);
100

100

101+
#if BLE_FEATURE_PRIVACY
101
result = init_resolving_list();
102
result = init_resolving_list();
103+
#endif
102

104

103
if (result != BLE_ERROR_NONE) {
105
if (result != BLE_ERROR_NONE) {
104
delete _db;
106
delete _db;
@@ -126,7 +128,9 @@ ble_error_t GenericSecurityManager<TPalSecurityManager, SigningMonitor>::setData
126
return result;
128
return result;
127
}
129
}
128

130

131+
#if BLE_FEATURE_PRIVACY
129
init_resolving_list();
132
init_resolving_list();
133+
#endif
130

134

131
return BLE_ERROR_NONE;
135
return BLE_ERROR_NONE;
132
}
136
}

features/FEATURE_BLE/targets/TARGET_CORDIO/source/CordioPalSecurityManager.tpp

Lines changed: 2 additions & 0 deletions
Original file line numberOriginal file lineDiff line numberDiff line change
@@ -45,7 +45,9 @@ CordioSecurityManager<EventHandler>::CordioSecurityManager() :
45
template <class EventHandler>
45
template <class EventHandler>
46
CordioSecurityManager<EventHandler>::~CordioSecurityManager()
46
CordioSecurityManager<EventHandler>::~CordioSecurityManager()
47
{
47
{
48+
#if BLE_FEATURE_PRIVACY
48
clear_privacy_control_blocks();
49
clear_privacy_control_blocks();
50+
#endif
49
}
51
}
50

52

51
////////////////////////////////////////////////////////////////////////////
53
////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)