Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1763943
  • 博文数量: 306
  • 博客积分: 3133
  • 博客等级: 中校
  • 技术积分: 3932
  • 用 户 组: 普通用户
  • 注册时间: 2009-04-19 16:50
文章分类

全部博文(306)

文章存档

2018年(7)

2017年(18)

2016年(39)

2015年(35)

2014年(52)

2013年(39)

2012年(22)

2011年(29)

2010年(53)

2009年(12)

分类: LINUX

2010-03-19 11:44:44

net/ipv4/tcp.c

* Description of States:
 *
 *    TCP_SYN_SENT        sent a connection request, waiting for ack
 *
 *    TCP_SYN_RECV        received a connection request, sent ack,
 *                waiting for final ack in three-way handshake.
 *
 *    TCP_ESTABLISHED        connection established
 *
 *    TCP_FIN_WAIT1        our side has shutdown, waiting to complete
 *                transmission of remaining buffered data
 *
 *    TCP_FIN_WAIT2        all buffered data sent, waiting for remote
 *                to shutdown
 *
 *    TCP_CLOSING        both sides have shutdown but we still have
 *                data we have to finish sending
 *
 *    TCP_TIME_WAIT        timeout to catch resent junk before entering
 *                closed, can only be entered from FIN_WAIT2
 *                or CLOSING.  Required because the other end
 *                may not have gotten our last ACK causing it
 *                to retransmit the data packet (which we ignore)
 *
 *    TCP_CLOSE_WAIT        remote side has shutdown and is waiting for
 *                us to finish writing our data and to shutdown
 *                (we have to close() to move on to LAST_ACK)
 *
 *    TCP_LAST_ACK        out side has shutdown after remote has
 *                shutdown.  There may still be data in our
 *                buffer that we have to finish sending
 *
 *    TCP_CLOSE        socket is finished
 */









阅读(2060) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~