[PATCH] fix loading static ips in Debian backend
- From: j bootlab org
- To: networkmanager-list gnome org
- Subject: [PATCH] fix loading static ips in Debian backend
- Date: Sun, 21 Aug 2005 19:57:15 +0200
attached patch makes loading static ips from /etc/network/interfaces
work again. by adding
sys_data->config = nm_ip4_config_new ();
j
--- orig/src/backends/NetworkManagerDebian.c
+++ mod/src/backends/NetworkManagerDebian.c
@@ -531,6 +531,8 @@
sys_data->use_dhcp = FALSE;
}
+ sys_data->config = nm_ip4_config_new ();
+
buf = ifparser_getkey (curr_device, "address");
if (buf)
nm_ip4_config_set_address (sys_data->config, inet_addr (buf));
@@ -570,10 +572,10 @@
#if 0
nm_debug ("------ Config (%s)", nm_device_get_iface (dev));
- nm_debug (" DHCP=%d\n", use_dhcp);
- nm_debug (" ADDR=%d\n", ip4_address);
- nm_debug (" GW=%d\n", ip4_gateway);
- nm_debug (" NM=%d\n", ip4_netmask);
+ nm_debug (" DHCP=%s\n", sys_data->use_dhcp);
+ nm_debug (" ADDR=%d\n", nm_ip4_config_get_address (sys_data->config));
+ nm_debug (" GW=%d\n", nm_ip4_config_get_gateway (sys_data->config));
+ nm_debug (" NM=%d\n", nm_ip4_config_get_netmask (sys_data->config));
nm_debug ("---------------------\n");
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]