struct hostent *data;
struct sockaddr_in server;
int sock;
sock = socket(AF_INET, SOCK_DGRAM , 0)
/* binding and all are done here */
data = gethostbyname("158.168.1.1");
memcpy (&server.sin_addrs, data->h_addr, data->h_length);
retval = sendto(sock,msg,sizeof(msg), 0, (struct sockaddr *) &server,
sizeof server);
Thanking You
Shesha
_________________________________________________________________
Cricket - World Cup 2003 http://server1.msn.co.in/msnspecials/worldcup03/
News, Views and Match Reports.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/