can anyone tell me how to print the IP address of the data type in_addr_t?
Which function call should I use?
Thanks in advance.
can anyone tell me how to print the IP address of the data type in_addr_t?
Which function call should I use?
Thanks in advance.
Hmm. Something like this?Check your man pages.Code:in_addr_t addr; /* ... */ puts(inet_ntoa(addr));
7. It is easier to write an incorrect program than understand a correct one.
40. There are two ways to write error-free programs; only the third one works.*