OK, I admit defeat - allow the user to override hostname and gateway
values set by dhcp.
This commit is contained in:
parent
7fc80cc95b
commit
2873f9a570
@ -363,13 +363,13 @@ tcpOpenDialog(Device *devp)
|
||||
char *pccard;
|
||||
|
||||
if (hostname[0]) {
|
||||
variable_set2(VAR_HOSTNAME, hostname, use_dhcp ? 0 : 1);
|
||||
variable_set2(VAR_HOSTNAME, hostname, 1);
|
||||
sethostname(hostname, strlen(hostname));
|
||||
}
|
||||
if (domainname[0])
|
||||
variable_set2(VAR_DOMAINNAME, domainname, 0);
|
||||
if (gateway[0])
|
||||
variable_set2(VAR_GATEWAY, gateway, use_dhcp ? 0 : 1);
|
||||
variable_set2(VAR_GATEWAY, gateway, 1);
|
||||
if (nameserver[0])
|
||||
variable_set2(VAR_NAMESERVER, nameserver, 0);
|
||||
if (ipaddr[0])
|
||||
|
@ -363,13 +363,13 @@ tcpOpenDialog(Device *devp)
|
||||
char *pccard;
|
||||
|
||||
if (hostname[0]) {
|
||||
variable_set2(VAR_HOSTNAME, hostname, use_dhcp ? 0 : 1);
|
||||
variable_set2(VAR_HOSTNAME, hostname, 1);
|
||||
sethostname(hostname, strlen(hostname));
|
||||
}
|
||||
if (domainname[0])
|
||||
variable_set2(VAR_DOMAINNAME, domainname, 0);
|
||||
if (gateway[0])
|
||||
variable_set2(VAR_GATEWAY, gateway, use_dhcp ? 0 : 1);
|
||||
variable_set2(VAR_GATEWAY, gateway, 1);
|
||||
if (nameserver[0])
|
||||
variable_set2(VAR_NAMESERVER, nameserver, 0);
|
||||
if (ipaddr[0])
|
||||
|
Loading…
Reference in New Issue
Block a user