James Bursa fixed a RISC OS init issue, removed trailing whitespace
This commit is contained in:
parent
8ee564c216
commit
80197cf493
@ -324,7 +324,7 @@ DhcpNameServer
|
|||||||
|
|
||||||
status = ARES_EFILE;
|
status = ARES_EFILE;
|
||||||
|
|
||||||
if (IsNT)
|
if (IsNT)
|
||||||
{
|
{
|
||||||
if (RegOpenKeyEx(
|
if (RegOpenKeyEx(
|
||||||
HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0,
|
HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0,
|
||||||
@ -368,7 +368,7 @@ DhcpNameServer
|
|||||||
if ((result = RegQueryValueEx(
|
if ((result = RegQueryValueEx(
|
||||||
mykey, NAMESERVER, NULL, &data_type,
|
mykey, NAMESERVER, NULL, &data_type,
|
||||||
NULL, &bytes
|
NULL, &bytes
|
||||||
)
|
)
|
||||||
) == ERROR_SUCCESS ||
|
) == ERROR_SUCCESS ||
|
||||||
result == ERROR_MORE_DATA)
|
result == ERROR_MORE_DATA)
|
||||||
{
|
{
|
||||||
@ -384,10 +384,10 @@ DhcpNameServer
|
|||||||
free(line);
|
free(line);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RegCloseKey(mykey);
|
RegCloseKey(mykey);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (status != ARES_EFILE)
|
if (status != ARES_EFILE)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
@ -404,7 +404,7 @@ DhcpNameServer
|
|||||||
system variable Inet$Resolvers, space separated. */
|
system variable Inet$Resolvers, space separated. */
|
||||||
|
|
||||||
line = getenv("Inet$Resolvers");
|
line = getenv("Inet$Resolvers");
|
||||||
status = ARES_EFILE;
|
status = ARES_EOF;
|
||||||
if (line) {
|
if (line) {
|
||||||
char *resolvers = strdup(line), *pos, *space;
|
char *resolvers = strdup(line), *pos, *space;
|
||||||
|
|
||||||
@ -424,7 +424,7 @@ DhcpNameServer
|
|||||||
|
|
||||||
if (status == ARES_SUCCESS)
|
if (status == ARES_SUCCESS)
|
||||||
status = ARES_EOF;
|
status = ARES_EOF;
|
||||||
|
|
||||||
free(resolvers);
|
free(resolvers);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -433,7 +433,7 @@ DhcpNameServer
|
|||||||
char *p;
|
char *p;
|
||||||
FILE *fp;
|
FILE *fp;
|
||||||
int linesize;
|
int linesize;
|
||||||
|
|
||||||
fp = fopen(PATH_RESOLV_CONF, "r");
|
fp = fopen(PATH_RESOLV_CONF, "r");
|
||||||
if (!fp)
|
if (!fp)
|
||||||
return (errno == ENOENT) ? ARES_SUCCESS : ARES_EFILE;
|
return (errno == ENOENT) ? ARES_SUCCESS : ARES_EFILE;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user