4 int main( int argc
, char **argv
) {
7 WSAStartup( 0x0101, &wdata
);
10 struct hostent
*he
= gethostbyname( argv
[1] );
12 printf( "lookup of host %s failed: %d\n", argv
[1], WSAGetLastError() );
15 printf( "Lookup of host %s returned %s\n",
16 argv
[1], inet_ntoa(*((struct in_addr
*)he
->h_addr_list
[0])) );