the output of the code is as below....
int getmacaddress(char* dev, unsigned char *ipmac);
unsigned char dot_not_mac;
printf(" the MAC address is %s\n",dot_not_mac);
int getmacaddress(char* dev,unsigned char *ipmac)
struct ifreq ifr;
skfd = socket(AF_INET,SOCK_DGRAM,0);
DEBUG1("Can't open socket!\n");
if(ioctl(skfd, SIOCGIFHWADDR, &ifr) < 0)
DEBUG1("Can't read local mac address!\n");
the MAC address is
can anyone tell me what is wrong with this code... this code is not working...it is not printing MAC address.... please help me..