Merge "Convert mask types from uint32_t to enum type" am: 1f551d879a

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1510239

Change-Id: I5a49cd9e90e5d3cd09f522c545fd4d1001937b42
This commit is contained in:
Treehugger Robot
2020-12-01 17:42:20 +00:00
committed by Automerger Merge Worker

View File

@@ -31,7 +31,7 @@ std::string deviceAddressToHal(const DeviceAddress& address) {
// HAL assumes that the address is NUL-terminated.
char halAddress[AUDIO_DEVICE_MAX_ADDRESS_LEN];
memset(halAddress, 0, sizeof(halAddress));
uint32_t halDevice = static_cast<uint32_t>(address.device);
audio_devices_t halDevice = static_cast<audio_devices_t>(address.device);
if (getAudioDeviceOutAllA2dpSet().count(halDevice) > 0 ||
halDevice == AUDIO_DEVICE_IN_BLUETOOTH_A2DP) {
snprintf(halAddress, sizeof(halAddress), "%02X:%02X:%02X:%02X:%02X:%02X",