diff --git a/Sources/BluetoothLinux/GATTClient.swift b/Sources/BluetoothLinux/GATTClient.swift index 1fa6da6..c17dc01 100755 --- a/Sources/BluetoothLinux/GATTClient.swift +++ b/Sources/BluetoothLinux/GATTClient.swift @@ -774,8 +774,7 @@ private extension GATTClient { @inline(__always) func success(_ attributes: [ATTReadByTypeResponse.AttributeData]) { - var data = [UInt16: Data]() - data.reserveCapacity(attributes.count) + var data = [UInt16: Data](minimumCapacity: attributes.count) for attribute in attributes {