|
|
|
@ -147,7 +147,6 @@ static int file_lookup(struct in_addr *addr, struct hostent **host) |
|
|
|
|
int status; |
|
|
|
|
|
|
|
|
|
#ifdef WIN32 |
|
|
|
|
|
|
|
|
|
char PATH_HOSTS[MAX_PATH]; |
|
|
|
|
if (IS_NT()) { |
|
|
|
|
char tmp[MAX_PATH]; |
|
|
|
@ -157,7 +156,7 @@ static int file_lookup(struct in_addr *addr, struct hostent **host) |
|
|
|
|
== ERROR_SUCCESS) |
|
|
|
|
{ |
|
|
|
|
DWORD dwLength = MAX_PATH; |
|
|
|
|
RegQueryValueEx(hkeyHosts, DATABASEPATH, NULL, NULL, tmp, |
|
|
|
|
RegQueryValueEx(hkeyHosts, DATABASEPATH, NULL, NULL, (LPBYTE)tmp, |
|
|
|
|
&dwLength); |
|
|
|
|
ExpandEnvironmentStrings(tmp, PATH_HOSTS, MAX_PATH); |
|
|
|
|
RegCloseKey(hkeyHosts); |
|
|
|
|