mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-10 08:10:22 +01:00
wifi-p2p: fix getting timeout argument from a{sv} variant for "StartFind"
Fixes: dd0c59c468
This commit is contained in:
parent
60691d76ad
commit
4aa34043da
1 changed files with 2 additions and 2 deletions
|
|
@ -1006,11 +1006,11 @@ impl_device_wifi_p2p_start_find (NMDBusObject *obj,
|
|||
NMDeviceWifiP2P *self = NM_DEVICE_WIFI_P2P (obj);
|
||||
NMDeviceWifiP2PPrivate *priv = NM_DEVICE_WIFI_P2P_GET_PRIVATE (self);
|
||||
gs_unref_variant GVariant *options = NULL;
|
||||
int timeout;
|
||||
gint32 timeout;
|
||||
|
||||
g_variant_get (parameters, "(@a{sv})", &options);
|
||||
|
||||
if (!g_variant_lookup (options, "Timeout", "^ai", &timeout)) {
|
||||
if (!g_variant_lookup (options, "Timeout", "i", &timeout)) {
|
||||
/* Default to running a find for 30s. */
|
||||
timeout = 30;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue