mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 09:24:57 +00:00
LibC: Stub out the rest of the getnameinfo flags
These are required for the compilation of some ports.
This commit is contained in:
parent
8074157c10
commit
d68242ba2f
2 changed files with 4 additions and 2 deletions
|
@ -788,8 +788,8 @@ int getnameinfo(const struct sockaddr* __restrict addr, socklen_t addrlen, char*
|
|||
const sockaddr_in* sin = reinterpret_cast<const sockaddr_in*>(addr);
|
||||
|
||||
if (host && hostlen > 0) {
|
||||
if (flags & NI_NAMEREQD)
|
||||
dbgln("getnameinfo flag NI_NAMEREQD not implemented");
|
||||
if (flags != 0)
|
||||
dbgln("getnameinfo flags are not implemented: {:#x}", flags);
|
||||
|
||||
if (!inet_ntop(AF_INET, &sin->sin_addr, host, hostlen)) {
|
||||
if (errno == ENOSPC)
|
||||
|
|
|
@ -93,6 +93,8 @@ struct addrinfo {
|
|||
#define NI_NUMERICHOST 1
|
||||
#define NI_NUMERICSERV 2
|
||||
#define NI_NAMEREQD 3
|
||||
#define NI_NOFQDN 4
|
||||
#define NI_DGRAM 5
|
||||
|
||||
int getaddrinfo(const char* __restrict node, const char* __restrict service, const struct addrinfo* __restrict hints, struct addrinfo** __restrict res);
|
||||
void freeaddrinfo(struct addrinfo* res);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue