core: use #define for "autoconnect-retries-default" config

All our known configuration keys should have a #define, so that
all keys are collected in the header file.
This commit is contained in:
Thomas Haller 2017-11-22 21:11:54 +01:00
parent a91dfa6a27
commit 1c631bda4e
2 changed files with 2 additions and 1 deletions

View file

@ -60,6 +60,7 @@
#define NM_CONFIG_KEYFILE_GROUP_IFNET "ifnet"
#define NM_CONFIG_KEYFILE_KEY_MAIN_AUTH_POLKIT "auth-polkit"
#define NM_CONFIG_KEYFILE_KEY_MAIN_AUTOCONNECT_RETRIES_DEFAULT "autoconnect-retries-default"
#define NM_CONFIG_KEYFILE_KEY_MAIN_DHCP "dhcp"
#define NM_CONFIG_KEYFILE_KEY_MAIN_DEBUG "debug"
#define NM_CONFIG_KEYFILE_KEY_MAIN_HOSTNAME_MODE "hostname-mode"

View file

@ -2530,7 +2530,7 @@ _autoconnect_retries_initial (NMSettingsConnection *self)
if (retries == -1) {
retries = nm_config_data_get_value_int64 (NM_CONFIG_GET_DATA,
NM_CONFIG_KEYFILE_GROUP_MAIN,
"autoconnect-retries-default",
NM_CONFIG_KEYFILE_KEY_MAIN_AUTOCONNECT_RETRIES_DEFAULT,
10, 0, G_MAXINT32,
AUTOCONNECT_RETRIES_DEFAULT);
}