1.网络协议设计ISO提出了OSI分层网络模型,这种分层模型是理论上的,TCP/IP最终实现了一个分层的协议模型,每一个层次对应一组网络协议完成一组特定的功能,该组网络协议被其下的层次复用和解复用。这就是分层模型的本质,最终所有的逻辑被编码到线缆或者电磁波。分层模型是很好理解的,然而对于每一层的协议... Read More
posted @ 2015-06-16 14:06
过去现在将来
Views(192)
Comments(0)
Diggs(0)
1.服务器端/*select_server.c 2011.9.2 by yyg*/#include #include #include #include #include #include #include #include #include #include #include #include #... Read More
posted @ 2015-06-16 13:53
过去现在将来
Views(328)
Comments(0)
Diggs(0)
1.服务器端#include #include #include #include #include #include #include #include #include #define MYPORT 3490 //定义端口#define BACKLOG 10#define MAXDATASIZ... Read More
posted @ 2015-06-16 13:52
过去现在将来
Views(164)
Comments(0)
Diggs(0)
以下描述主要是针对windows平台下的TCP socket而言。首先需要区分一下关闭socket和关闭TCP连接的区别,关闭TCP连接是指TCP协议层的东西,就是两个TCP端之间交换了一些协议包(FIN,RST等),具体的交换过程可以看TCP协议,这里不详细描述了。而关闭socket是指关闭用户应... Read More
posted @ 2015-06-16 13:46
过去现在将来
Views(12292)
Comments(0)
Diggs(0)

浙公网安备 33010602011771号