Hi all,
char temp[50];
printf("Current system IP is: %s", inet_ntoa(*((struct in_addr *)temp)));
I have these lines, and it's basically feeding me with crap IP addresses (one is a 252.x.x.x...
Type: Posts; User: PhilB
Hi all,
char temp[50];
printf("Current system IP is: %s", inet_ntoa(*((struct in_addr *)temp)));
I have these lines, and it's basically feeding me with crap IP addresses (one is a 252.x.x.x...
Awesome, I will do - I'm awaiting a work permit (I come from the UK), so I'm a little strapped for cash, otherwise I'd buy some books :P
Thanks for your help,
Thanks very much, from that I'll be able to decipher networking C a little more.
The code worked, and compiled for me using cc version 2.96 on Redhat Linux 7.0 kernel 2.4.18
Hi all,
I'm writing a small program to allow my Linux illiterate wife to obtain system/network diagnostics for our 'net connection on Linux (Redhat 7). I am wanting to provide such things as IP...