0

I am working on a project with an embedded TCP/IP-socket implementation.

My problem is my overlaying SDK needs needs the function:

getaddrinfo( PCSTR pNodeName, PCSTR pServiceName, const ADDRINFOA *pHints, PADDRINFOA *ppResult );

but my underlying embedded "OS" is just providing the function:

struct* hostent gethostbyname(const char * sName);

Has someone an easy solution how to fake getaddrinfo() for the SDK, without the necessary to write it my self?

https://www.segger.com/downloads/emnet/UM07001 (page 273)

https://learn.microsoft.com/en-us/windows/win32/api/ws2tcpip/nf-ws2tcpip-getaddrinfo

enter image description here

Clifford
  • 88,407
  • 13
  • 85
  • 165
  • emNet != embOS It is an emNet question, not an embOS question - that is it is not specific you tour RTOS – Clifford May 04 '21 at 09:24
  • `getaddrinfo()` is not a trivial function (https://code.woboq.org/userspace/glibc/sysdeps/posix/getaddrinfo.c.html) you are asking a lot. – Clifford May 04 '21 at 10:02

0 Answers0