#3381: DNS::hostByAddress not thread-safe

This commit is contained in:
Günter Obiltschnig 2021-11-05 13:18:06 +01:00
parent c908cbe6fe
commit fc0cc6af36

View File

@ -117,7 +117,7 @@ HostEntry DNS::hostByAddress(const IPAddress& address, unsigned
#if defined(POCO_HAVE_ADDRINFO)
SocketAddress sa(address, 0);
static char fqname[1024];
char fqname[1024];
int rc = getnameinfo(sa.addr(), sa.length(), fqname, sizeof(fqname), NULL, 0, NI_NAMEREQD);
if (rc == 0)
{