Skip to content

Commit 39f5e56

Browse files
committed
[0.4.9] [NFSD] Apply a hack to avoid CORE-13498
Committing into rls was requested by Pierre. The hack allows to startup nfsd even when getnameinfo() fails.
1 parent 4268605 commit 39f5e56

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

base/services/nfsd/nfs41_daemon.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,8 +309,17 @@ static int getdomainname()
309309
(socklen_t)ptr->ai_addrlen, hostname, NI_MAXHOST,
310310
servInfo, NI_MAXSERV, NI_NAMEREQD);
311311
if (status)
312+
#if 0
312313
dprintf(1, "getnameinfo failed %d\n", WSAGetLastError());
313314
else {
315+
#else
316+
{
317+
dprintf(1, "getnameinfo failed %d, forcing name\n", WSAGetLastError());
318+
memcpy(hostname, "reactos.home", sizeof("reactos.home"));
319+
status = 0;
320+
}
321+
{
322+
#endif
314323
size_t i, len = strlen(hostname);
315324
char *p = hostname;
316325
dprintf(1, "getdomainname: hostname %s %d\n", hostname, len);

0 commit comments

Comments
 (0)