[network-manager-applet] eap-method: fix uninitialized errors



commit 26f2bfbf474bde52e9574cfbb7a68de4f958beec
Author: Lubomir Rintel <lkundrak v3 sk>
Date:   Tue Jun 13 15:42:17 2017 +0200

    eap-method: fix uninitialized errors
    
    CID 170707 (#1 of 2): Uninitialized scalar variable (UNINIT)
    20. uninit_use_in_call: Using uninitialized value scheme when calling nm_setting_802_1x_set_ca_cert

 src/wireless-security/eap-method-peap.c |    2 +-
 src/wireless-security/eap-method-ttls.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/wireless-security/eap-method-peap.c b/src/wireless-security/eap-method-peap.c
index 4c65ade..81bd275 100644
--- a/src/wireless-security/eap-method-peap.c
+++ b/src/wireless-security/eap-method-peap.c
@@ -148,7 +148,7 @@ fill_connection (EAPMethod *parent, NMConnection *connection)
        int peapver_active = 0;
        GError *error = NULL;
        gboolean ca_cert_error = FALSE;
-       NMSetting8021xCKScheme scheme;
+       NMSetting8021xCKScheme scheme = NM_SETTING_802_1X_CK_SCHEME_UNKNOWN;
 #if LIBNM_BUILD
        NMSettingSecretFlags secret_flags;
 #endif
diff --git a/src/wireless-security/eap-method-ttls.c b/src/wireless-security/eap-method-ttls.c
index 7244477..4e9201f 100644
--- a/src/wireless-security/eap-method-ttls.c
+++ b/src/wireless-security/eap-method-ttls.c
@@ -146,7 +146,7 @@ fill_connection (EAPMethod *parent, NMConnection *connection)
        GtkTreeModel *model;
        GtkTreeIter iter;
        GError *error = NULL;
-       NMSetting8021xCKScheme scheme;
+       NMSetting8021xCKScheme scheme = NM_SETTING_802_1X_CK_SCHEME_UNKNOWN;
        gboolean ca_cert_error = FALSE;
 
        s_8021x = nm_connection_get_setting_802_1x (connection);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]