diff options
author | Christian Kandeler <christian.kandeler@theqtcompany.com> | 2015-10-15 13:49:30 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@theqtcompany.com> | 2015-10-15 14:31:50 +0000 |
commit | cbc70bc3a2ea7fb545c2d9cfb8914d50c1ba6475 (patch) | |
tree | c42d39f78d3e5284d9673ab007c6db49dc387e09 /src/bluetooth/bluez | |
parent | 62ecca3d957f80d9acc7116d362517b03b2301a3 (diff) |
Bluetooth socket: Simplify address conversion.
In most cases, callers of convertAddress() feed the result into a
QBluetoothAddress, so they have no need for the output parameter.
Change-Id: I23b2e8d5d49ac300c35d141b75ffa8e398e22f19
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Diffstat (limited to 'src/bluetooth/bluez')
-rw-r--r-- | src/bluetooth/bluez/hcimanager.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/bluetooth/bluez/hcimanager.cpp b/src/bluetooth/bluez/hcimanager.cpp index bf2754f5..30511ae5 100644 --- a/src/bluetooth/bluez/hcimanager.cpp +++ b/src/bluetooth/bluez/hcimanager.cpp @@ -219,12 +219,8 @@ QBluetoothAddress HciManager::addressForConnectionHandle(quint16 handle) const } for (int i = 0; i < infoList->conn_num; i++) { - if (info[i].handle == handle) { - quint64 converted; - convertAddress(info[i].bdaddr.b, converted); - - return QBluetoothAddress(converted); - } + if (info[i].handle == handle) + return QBluetoothAddress(convertAddress(info[i].bdaddr.b)); } return QBluetoothAddress(); |