- 博客(8)
- 收藏
- 关注
转载 TCP/IP,http,socket,长连接,短连接——小结
TCP/IP,http,socket,长连接,短连接——小结 thomescai http://blog.csdn.net/thomescai(转载请保留) 概要: 之前对这几个概念有点糊涂,查阅了些资料,稍微概括下他们的区别吧。如有错误,请拍~~~ 先看图: TCP/IP是什么? TCP/IP是个协议组,可分为
2012-06-27 17:35:20 2504
原创 Socket Configuration Options
Socket Configuration Options: Socket options: One can "get" (read) the current socket options or "set" them to new values. The default values are obtained from the OS: Level Option
2012-06-21 13:45:42 1685
转载 TCP连接的建立(三次握手)和释放(四次握手)
TCP报文段首部格式: 序号:本报文段所发送的数据的第一个字节的序号。 确认号ack:期待收到对方下一个报文段的第一个数据字节的序号 确认ACK:占1位,仅当ACK=1时,确认号字段才有效。ACK=0时,确认号无效 同步SYN:连接建立时用于同步序号。当SYN=1,ACK=0时表示:这是一个连接请求报文段。 若同意连接,则在响应报文段中使得
2012-06-21 13:37:12 1194
原创 Socket BSD API man pages
Socket BSD API man pages: Sockets API: socket: establish socket interfacegethostname: obtain hostname of systemgethostbyname: returns a structure of type hostent for the given host namebin
2012-06-21 13:19:27 545
转载 Linux 套接字编程中的 5 个隐患
Linux 套接字编程中的 5 个隐患 在异构环境中开发可靠的网络应用程序 M. Tim Jones ([email protected]), 资深软件工程师, Emulex 简介: Socket API 是网络应用程序开发中实际应用的标准 API。尽管该 API 简单,但是开发新手可能会经历一些常见的问题。本文识别一些最常见的隐患并向您显示如何避免它们。
2012-06-21 09:47:41 454
转载 socket send recv
int send( SOCKET s, const char FAR *buf, int len, int flags ); 不论是客户还是服务器应用程序都用send函数来向TCP连接的另一端发送数据。 客户程序一般用send函数向服务器发送请求,而服务器则通常用send函数来向客户程序发送应答。 该函数的第一个参数指定发送端套接字描述符; 第二个参数指明一个存放应用程序
2012-06-19 13:07:48 535
原创 数组 strlen sizeof
#include #include #define _TEST_ #define BUF_SIZE 10 int main(int argc, char *argv[]) { int i; char sendBuff[BUF_SIZE]; memset(sendBuff, '0', sizeof(sendBuff));//init 0x30 #if
2012-06-19 10:04:54 530
转载 C Socket Programming for Linux
C Socket Programming for Linux with a Server and Client Example Code Typically two processes communicate with each other on a single system through one of the following inter process communic
2012-06-17 17:25:17 1328
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人