I've included sys/types.h, sys/socket.h, netdb.h, and arpa/inet.h.
And this is the output..
Code:
../../../sockets.cpp: In constructor `network_class::network_class()': ../../../sockets.cpp:64: error: aggregate `addrinfo hints' has incomplete type a nd cannot be defined ../../../sockets.cpp:69: error: `getaddrinfo' undeclared (first use