摘要:
#include <sys/socket.h>#include <netdb.h>#include <unistd.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include <signal.h>#include <memor 阅读全文
posted @ 2017-03-05 21:11
lvdh1314
阅读(194)
评论(0)
推荐(0)
摘要:
广播实现一对多的通信,通过向广播地址发送数据报文实现 只有udp的程序才能广播,tcp不能 #include <sys/socket.h>#include <netdb.h>#include <unistd.h>#include <string.h>#include <stdlib.h>#inclu 阅读全文
posted @ 2017-03-05 21:01
lvdh1314
阅读(154)
评论(0)
推荐(0)
摘要:
#include <sys/socket.h>#include <netdb.h>#include <unistd.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include <signal.h>#include <memor 阅读全文
posted @ 2017-03-05 20:31
lvdh1314
阅读(1167)
评论(0)
推荐(0)
摘要:
在/etc/hosts中已经设置了ip与域名的映射关系,通过域名解析函数进行解析(主机名,别名,协议类型,网络地址大小,指向网络IP地址指针等) 部分解析函数: #include<netdb.h> struct hostent gethostbyname(const char *hostname); 阅读全文
posted @ 2017-03-05 20:17
lvdh1314
阅读(154)
评论(0)
推荐(0)
摘要:
#include <sys/socket.h>#include <netdb.h>#include <unistd.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include <signal.h>#include <memor 阅读全文
posted @ 2017-03-05 10:21
lvdh1314
阅读(208)
评论(0)
推荐(0)
摘要:
#include <sys/socket.h>#include <netdb.h>#include <unistd.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include <signal.h>#include <time. 阅读全文
posted @ 2017-03-05 10:03
lvdh1314
阅读(246)
评论(0)
推荐(0)

浙公网安备 33010602011771号