mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-22 16:20:46 +02:00
core/wifi: minor cleanup in _bss_info_properties_changed()
Move local variables to inner scope. Also, drop code comment that doesn't give additional information beyond what is already plainly visible in source code.
This commit is contained in:
parent
7ccd2bb35e
commit
277044de10
1 changed files with 2 additions and 5 deletions
|
|
@ -481,8 +481,6 @@ _bss_info_properties_changed (NMSupplicantInterface *self,
|
|||
guint8 p_signal_percent;
|
||||
const guint8 *arr_data;
|
||||
gsize arr_len;
|
||||
gboolean p_metered;
|
||||
gboolean p_owe_transition_mode = FALSE;
|
||||
guint32 p_max_rate;
|
||||
gboolean p_max_rate_has;
|
||||
gint64 now_msec = 0;
|
||||
|
|
@ -628,6 +626,8 @@ _bss_info_properties_changed (NMSupplicantInterface *self,
|
|||
}
|
||||
v_v = nm_g_variant_lookup_value (properties, "IEs", G_VARIANT_TYPE_BYTESTRING);
|
||||
if (v_v) {
|
||||
gboolean p_owe_transition_mode;
|
||||
gboolean p_metered;
|
||||
guint32 rate;
|
||||
|
||||
arr_data = g_variant_get_fixed_array (v_v, &arr_len, 1);
|
||||
|
|
@ -636,8 +636,6 @@ _bss_info_properties_changed (NMSupplicantInterface *self,
|
|||
p_max_rate_has = TRUE;
|
||||
g_variant_unref (v_v);
|
||||
|
||||
|
||||
/* Add OWE Security type if OWE transition mode is available */
|
||||
if (p_owe_transition_mode)
|
||||
bss_info->rsn_flags |= NM_802_11_AP_SEC_KEY_MGMT_OWE;
|
||||
else
|
||||
|
|
@ -648,7 +646,6 @@ _bss_info_properties_changed (NMSupplicantInterface *self,
|
|||
if (p_max_rate_has)
|
||||
bss_info->max_rate = p_max_rate / 1000u;
|
||||
|
||||
|
||||
v_v = nm_g_variant_lookup_value (properties, "WPA", G_VARIANT_TYPE_VARDICT);
|
||||
if (v_v) {
|
||||
bss_info->wpa_flags = security_from_vardict (v_v);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue