摘要:
//VC 6.0 SOCKET相关代码已启动//客户端主要代码如下:SOCKADDR_IN addr;int broad = 1;SOCKET fd = socket(AF_INET,SOCK_DGRAM,0);setsockopt(fd,SOL_SOCKET,SO_BROADCAST,(const char *)&broad,sizeof(broad));addr.sin_addr.Sun.S_addr = INADDR_BROADCAST;addr.sin_family = AF_INET;addr.sin_port = htons(1234);sendto(fd,recved,s 阅读全文