Added handling for DNS field. Note: DNS will not work unless 'resolvconf' is installed.

This commit is contained in:
Druco committed 2018-07-16 03:36:01 -07:00
1 parent a4d7a10553
commit 50bb7448e7
2 files changed
+12 -1

No files matched your search

+2
View File
@@ -1118,6 +1118,7 @@ create_config_string (NMConnection *connection, GError **error)
const char *allowed_ips;
const char *endpoint;
const char *psk;
const char *dns;
char *value = NULL;
char **ip_list, **ip_iter;
GArray *ips;
@@ -1143,6 +1144,7 @@ create_config_string (NMConnection *connection, GError **error)
allowed_ips = _arg_is_set(nm_setting_vpn_get_data_item(s_vpn, NM_WG_KEY_ALLOWED_IPS));
endpoint = _arg_is_set(nm_setting_vpn_get_data_item(s_vpn, NM_WG_KEY_ENDPOINT));
psk = _arg_is_set(nm_setting_vpn_get_data_item(s_vpn, NM_WG_KEY_PRESHARED_KEY));
dns = _arg_is_set(nm_setting_vpn_get_data_item(s_vpn, NM_WG_KEY_DNS));
if(!ip4 && !ip6){
g_set_error_literal(error,