mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-26 21:50:44 +02:00
bluetooth: fix crash creating device
Due to the hardware address changes in 77dda53b (danw/hwlen) creating
a new Bluetooth device was crashing. The changes there assumed that the
NMDeviceBt's hardware address should only be valid when we were connected
to the device, but that's not quite true. Since we already know the remote
device's Bluetooth hardware address, we already know the hardware address
for the NMDeviceBt as well.
This commit is contained in:
parent
290c51da68
commit
caed0243f5
1 changed files with 2 additions and 6 deletions
|
|
@ -115,12 +115,8 @@ guint32 nm_device_bt_get_capabilities (NMDeviceBt *self)
|
|||
static guint
|
||||
get_hw_address_length (NMDevice *device)
|
||||
{
|
||||
NMDeviceBtPrivate *priv = NM_DEVICE_BT_GET_PRIVATE (device);
|
||||
|
||||
if (priv->have_iface)
|
||||
return ETH_ALEN;
|
||||
else
|
||||
return 0;
|
||||
/* HW address is the Bluetooth HW address of the remote device */
|
||||
return ETH_ALEN;
|
||||
}
|
||||
|
||||
static guint32
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue