use set value on return

pull/8738/head
paul-szczepanek-arm 2018-11-11 21:19:08 +00:00 committed by Vincent Coubard
parent 5e6c0c92f6
commit bd8b7fa87f
2 changed files with 4 additions and 4 deletions

View File

@ -140,13 +140,13 @@ public:
_enabledPhy[ble::phy_t::LE_CODED] * 1);
}
ble::phy_set_t getPhySet() const {
uint8_t getPhySet() const {
ble::phy_set_t set(
_enabledPhy[ble::phy_t::LE_1M],
_enabledPhy[ble::phy_t::LE_2M],
_enabledPhy[ble::phy_t::LE_CODED]
);
return set;
return set.value();
}
/* these return pointers to arrays of settings valid only across the number of active PHYs */

View File

@ -611,9 +611,9 @@ ble_error_t GenericGap::connect(
return _pal_gap.extended_create_connection(
(ble::pal::initiator_policy_t::type)connectionParams.getFilterPolicy(),
(ble::pal::own_address_type_t::type)connectionParams.getOwnAddressType().value(),
(ble::peer_address_type_t)peerAddressType.value(),
(ble::peer_address_type_t::type)peerAddressType.value(),
peerAddress,
connectionParams.getNumberOfEnabledPhys(),
(ble::phy_set_t)connectionParams.getPhySet(),
connectionParams.getScanIntervalArray(),
connectionParams.getScanWindowArray(),
connectionParams.getMinConnectionIntervalArray(),