亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? tcp_input.c

?? vxwork源代碼
?? C
?? 第 1 頁 / 共 5 頁
字號:
		if ((tiflags & TH_SYN) == 0)			goto drop;		if (tiflags & TH_ACK) {			tp->snd_una = ti->ti_ack;			if (SEQ_LT(tp->snd_nxt, tp->snd_una))				tp->snd_nxt = tp->snd_una;                        tp->t_timer[TCPT_REXMT] = 0;		}		tp->irs = ti->ti_seq;		tcp_rcvseqinit(tp);		tp->t_flags |= TF_ACKNOW;		if (tiflags & TH_ACK ) {			tcpstat.tcps_connects++;#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_INFO event */            WV_NET_PORTIN_EVENT_3 (NET_AUX_EVENT, WV_NET_INFO, 30, 12,                                   ti->ti_sport, ti->ti_dport,                                   WV_NETEVENT_TCPIN_CONNECT, WV_NET_RECV,                                    so->so_fd, tp->snd_nxt, tp->rcv_nxt)#endif  /* INCLUDE_WVNET */#endif			soisconnected(so);			tp->t_state = TCPS_ESTABLISHED;			/* Do window scaling on this connection? */			if ((tp->t_flags & (TF_RCVD_SCALE|TF_REQ_SCALE)) ==				(TF_RCVD_SCALE|TF_REQ_SCALE)) {				tp->snd_scale = tp->requested_s_scale;				tp->rcv_scale = tp->request_r_scale;			}			(void) tcp_reass(tp, (struct tcpiphdr *)0,				(struct mbuf *)0);			/*			 * if we didn't have to retransmit the SYN,			 * use its rtt as our initial srtt & rtt var.			 */			if (tp->t_rtt)				tcp_xmit_timer(tp, tp->t_rtt);		} else			tp->t_state = TCPS_SYN_RECEIVED;trimthenstep6:		/*		 * Advance ti->ti_seq to correspond to first data byte.		 * If data, trim to stay within window,		 * dropping FIN if necessary.		 */		ti->ti_seq++;		if (ti->ti_len > tp->rcv_wnd) {			todrop = ti->ti_len - tp->rcv_wnd;			m_adj(m, -todrop);			ti->ti_len = tp->rcv_wnd;			tiflags &= ~TH_FIN;			tcpstat.tcps_rcvpackafterwin++;			tcpstat.tcps_rcvbyteafterwin += todrop;		}		tp->snd_wl1 = ti->ti_seq - 1;		tp->rcv_up = ti->ti_seq;		goto step6;	}	/*	 * States other than LISTEN or SYN_SENT.	 * First check timestamp, if present.	 * Then check that at least some bytes of segment are within 	 * receive window.  If segment begins before rcv_nxt,	 * drop leading data (and SYN); if nothing left, just ack.	 * 	 * RFC 1323 PAWS: If we have a timestamp reply on this segment	 * and it's less than ts_recent, drop it.	 */	if (ts_present && (tiflags & TH_RST) == 0 && tp->ts_recent &&	    TSTMP_LT(ts_val, tp->ts_recent)) {		/* Check to see if ts_recent is over 24 days old.  */		if ((int)(tcp_now - tp->ts_recent_age) > TCP_PAWS_IDLE) {			/*			 * Invalidate ts_recent.  If this segment updates			 * ts_recent, the age will be reset later and ts_recent			 * will get a valid value.  If it does not, setting			 * ts_recent to zero will at least satisfy the			 * requirement that zero be placed in the timestamp			 * echo reply when ts_recent isn't valid.  The			 * age isn't reset until we get a valid ts_recent			 * because we don't want out-of-order segments to be			 * dropped when ts_recent is old.			 */			tp->ts_recent = 0;		} else {			tcpstat.tcps_rcvduppack++;			tcpstat.tcps_rcvdupbyte += ti->ti_len;			tcpstat.tcps_pawsdrop++;			goto dropafterack;		}	}	todrop = tp->rcv_nxt - ti->ti_seq;	if (todrop > 0) {		if (tiflags & TH_SYN) {			tiflags &= ~TH_SYN;			ti->ti_seq++;			if (ti->ti_urp > 1) 				ti->ti_urp--;			else				tiflags &= ~TH_URG;			todrop--;		}#if 0  /* simultaneous open bug  */              		if (todrop >= ti->ti_len) {			tcpstat.tcps_rcvduppack++;			tcpstat.tcps_rcvdupbyte += ti->ti_len;			/*			 * If segment is just one to the left of the window,			 * check two special cases:			 * 1. Don't toss RST in response to 4.2-style keepalive.			 * 2. If the only thing to drop is a FIN, we can drop			 *    it, but check the ACK or we will get into FIN			 *    wars if our FINs crossed (both CLOSING).			 * In either case, send ACK to resynchronize,			 * but keep on processing for RST or ACK.			 */			if ((tiflags & TH_FIN && todrop == ti->ti_len + 1)#ifdef TCP_COMPAT_42			  || (tiflags & TH_RST && ti->ti_seq == tp->rcv_nxt - 1)#endif			   ) {				todrop = ti->ti_len;				tiflags &= ~TH_FIN;			} else {				/*				 * Handle the case when a bound socket connects				 * to itself. Allow packets with a SYN and				 * an ACK to continue with the processing.				 */				if (todrop != 0 || (tiflags & TH_ACK) == 0)					goto dropafterack;			}			tp->t_flags |= TF_ACKNOW;		} else {			tcpstat.tcps_rcvpartduppack++;			tcpstat.tcps_rcvpartdupbyte += todrop;		}#else /* XXX  simultaneous open bug fix Steven vol II sec 28.8 fig 28.30 */                if (todrop > ti->ti_len ||                    (todrop == ti->ti_len && (tiflags & TH_FIN) == 0)) {                    /*                     * Any valid Fin must be to the left of the window.                     * At this point the FIN must be a duplicate or                     * out of sequence; drop it.                     */                     tiflags &= ~TH_FIN;                    /*                     * Send an ACK to resynchronize and drop any data.                     * But keep on processing for RST or ACK.                     */                    tp->t_flags |= TF_ACKNOW;                    todrop = ti->ti_len;                }                tcpstat.tcps_rcvdupbyte += todrop;                tcpstat.tcps_rcvduppack++;#endif /* simultaneous open bug fix */                   		m_adj(m, todrop);		ti->ti_seq += todrop;		ti->ti_len -= todrop;		if (ti->ti_urp > todrop)			ti->ti_urp -= todrop;		else {			tiflags &= ~TH_URG;			ti->ti_urp = 0;		}	}	/*	 * If new data are received on a connection after the	 * user processes are gone, then RST the other end.	 */	if ((so->so_state & SS_NOFDREF) &&	    tp->t_state > TCPS_CLOSE_WAIT && ti->ti_len) {		tp = tcp_close(tp);		tcpstat.tcps_rcvafterclose++;#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_INFO event */        WV_NET_PORTIN_EVENT_3 (NET_CORE_EVENT, WV_NET_INFO, 31, 13,                               ti->ti_sport, ti->ti_dport,                               WV_NETEVENT_TCPIN_DATACLOSED, WV_NET_RECV,                                so->so_fd, ti->ti_seq, ti->ti_len)#endif  /* INCLUDE_WVNET */#endif		goto dropwithreset;	}	/*	 * If segment ends after window, drop trailing data	 * (and PUSH and FIN); if nothing left, just ACK.	 */	todrop = (ti->ti_seq+ti->ti_len) - (tp->rcv_nxt+tp->rcv_wnd);	if (todrop > 0) {		tcpstat.tcps_rcvpackafterwin++;		if (todrop >= ti->ti_len) {			tcpstat.tcps_rcvbyteafterwin += ti->ti_len;			/*			 * If a new connection request is received			 * while in TIME_WAIT, drop the old connection			 * and start over if the sequence numbers			 * are above the previous ones.			 */			if (tiflags & TH_SYN &&			    tp->t_state == TCPS_TIME_WAIT &&			    SEQ_GT(ti->ti_seq, tp->rcv_nxt)) {				iss = tp->snd_nxt + TCP_ISSINCR;				tp = tcp_close(tp);				goto findpcb;			}			/*			 * If window is closed can only take segments at			 * window edge, and have to drop data and PUSH from			 * incoming segments.  Continue processing, but			 * remember to ack.  Otherwise, drop segment			 * and ack.			 */			if (tp->rcv_wnd == 0 && ti->ti_seq == tp->rcv_nxt) {				tp->t_flags |= TF_ACKNOW;				tcpstat.tcps_rcvwinprobe++;			} else				goto dropafterack;		} else			tcpstat.tcps_rcvbyteafterwin += todrop;		m_adj(m, -todrop);		ti->ti_len -= todrop;		tiflags &= ~(TH_PUSH|TH_FIN);	}	/*	 * If last ACK falls within this segment's sequence numbers,	 * record its timestamp.	 */	if (ts_present && TSTMP_GEQ(ts_val, tp->ts_recent) &&            SEQ_LEQ(ti->ti_seq, tp->last_ack_sent)) {		tp->ts_recent_age = tcp_now;		tp->ts_recent = ts_val;	}	/*	 * If the RST bit is set examine the state:	 *    SYN_RECEIVED STATE:	 *	If passive open, return to LISTEN state.	 *	If active open, inform user that connection was refused.	 *    ESTABLISHED, FIN_WAIT_1, FIN_WAIT2, CLOSE_WAIT STATES:	 *	Inform user that connection was reset, and close tcb.	 *    CLOSING, LAST_ACK, TIME_WAIT STATES	 *	Close the tcb.	 */	if (tiflags&TH_RST) switch (tp->t_state) {	case TCPS_SYN_RECEIVED:		so->so_error = ECONNREFUSED;		goto close;	case TCPS_ESTABLISHED:	case TCPS_FIN_WAIT_1:	case TCPS_FIN_WAIT_2:	case TCPS_CLOSE_WAIT:		so->so_error = ECONNRESET;	close:#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_INFO event */        WV_NET_PORTIN_EVENT_1 (NET_AUX_EVENT, WV_NET_INFO, 32, 14,                               ti->ti_sport, ti->ti_dport,                               WV_NETEVENT_TCPIN_RESET, WV_NET_RECV,                                so->so_fd)#endif  /* INCLUDE_WVNET */#endif		tp->t_state = TCPS_CLOSED;		tcpstat.tcps_drops++;		tp = tcp_close(tp);		goto drop;	case TCPS_CLOSING:	case TCPS_LAST_ACK:	case TCPS_TIME_WAIT:		tp = tcp_close(tp);		goto drop;	}	/*	 * If a SYN is in the window, then this is an	 * error and we send an RST and drop the connection.	 */	if (tiflags & TH_SYN) {#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_WARNING event */        WV_NET_PORTIN_EVENT_1 (NET_CORE_EVENT, WV_NET_WARNING, 12, 5,                               ti->ti_sport, ti->ti_dport,                               WV_NETEVENT_TCPIN_BADSYNC, WV_NET_RECV,                                so->so_fd)#endif  /* INCLUDE_WVNET */#endif		tp = tcp_drop(tp, ECONNRESET);		goto dropwithreset;	}	/*	 * If the ACK bit is off we drop the segment and return.	 */	if ((tiflags & TH_ACK) == 0)		goto drop;		/*	 * Ack processing.	 */	switch (tp->t_state) {	/*	 * In SYN_RECEIVED state if the ack ACKs our SYN then enter	 * ESTABLISHED state and continue processing, otherwise	 * send an RST.	 */	case TCPS_SYN_RECEIVED:		if (SEQ_GT(tp->snd_una, ti->ti_ack) ||		    SEQ_GT(ti->ti_ack, tp->snd_max))			goto dropwithreset;#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_INFO event */            WV_NET_PORTIN_EVENT_3 (NET_AUX_EVENT, WV_NET_INFO, 30, 12,                                   ti->ti_sport, ti->ti_dport,                                   WV_NETEVENT_TCPIN_CONNECT, WV_NET_RECV,                                    so->so_fd, tp->snd_nxt, tp->rcv_nxt)#endif  /* INCLUDE_WVNET */#endif		tcpstat.tcps_connects++;		soisconnected(so);		tp->t_state = TCPS_ESTABLISHED;		/* Do window scaling? */		if ((tp->t_flags & (TF_RCVD_SCALE|TF_REQ_SCALE)) ==			(TF_RCVD_SCALE|TF_REQ_SCALE)) {			tp->snd_scale = tp->requested_s_scale;			tp->rcv_scale = tp->request_r_scale;		}		(void) tcp_reass(tp, (struct tcpiphdr *)0, (struct mbuf *)0);		tp->snd_wl1 = ti->ti_seq - 1;		/* fall into ... */	/*	 * In ESTABLISHED state: drop duplicate ACKs; ACK out of range	 * ACKs.  If the ack is in the range	 *	tp->snd_una < ti->ti_ack <= tp->snd_max	 * then advance tp->snd_una to ti->ti_ack and drop	 * data from the retransmission queue.  If this ACK reflects	 * more up to date window information we update our window information.	 */	case TCPS_ESTABLISHED:	case TCPS_FIN_WAIT_1:	case TCPS_FIN_WAIT_2:	case TCPS_CLOSE_WAIT:	case TCPS_CLOSING:	case TCPS_LAST_ACK:	case TCPS_TIME_WAIT:		if (SEQ_LEQ(ti->ti_ack, tp->snd_una)) {			if (ti->ti_len == 0 && tiwin == tp->snd_wnd) {				tcpstat.tcps_rcvdupack++;				/*				 * If we have outstanding data (other than				 * a window probe), this is a completely				 * duplicate ack (ie, window info didn't				 * change), the ack is the biggest we've				 * seen and we've seen exactly our rexmt				 * threshhold of them, assume a packet				 * has been dropped and retransmit it.				 * Kludge snd_nxt & the congestion				 * window so we send only this one				 * packet.				 *				 * We know we're losing at the current				 * window size so do congestion avoidance				 * (set ssthresh to half the current window				 * and pull our congestion window back to				 * the new ssthresh).				 *				 * Dup acks mean that packets have left the				 * network (they're now cached at the receiver) 				 * so bump cwnd by the amount in the receiver				 * to keep a constant cwnd packets in the				 * network.				 */				if (tp->t_timer[TCPT_REXMT] == 0 ||				    ti->ti_ack != tp->snd_una)					tp->t_dupacks = 0;				else if (++tp->t_dupacks == tcprexmtthresh) {					tcp_seq onxt = tp->snd_nxt;					u_int win =					    min(tp->snd_wnd, tp->snd_cwnd) / 2 /						tp->t_maxseg;					if (win < 2)						win = 2;					tp->snd_ssthresh = win * tp->t_maxseg;					tp->t_timer[TCPT_REXMT] = 0;					tp->t_rtt = 0;					tp->snd_nxt = ti->ti_ack;					tp->snd_cwnd = tp->t_maxseg;#ifdef WV_INSTRUMENTATION#ifdef INCLUDE_WVNET    /* WV_NET_WARNING event */            WV_NET_PORTOUT_EVENT_2 (NET_CORE_EVENT, WV_NET_WARNING, 13, 6,                              tp->t_inpcb->inp_lport, tp->t_inpcb->inp_fport,                                   WV_NETEVENT_TCPIN_SENDFAIL, WV_NET_RECV,                                    so->so_fd, tp->t_dupacks)#endif  /* INCLUDE_WVNET */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩电影在线一区二区三区| 中文字幕视频一区| 国产日韩欧美麻豆| 樱花草国产18久久久久| 久久精品国产免费| 欧美亚洲国产一区二区三区va| 精品三级在线观看| 一区二区成人在线| 粉嫩av一区二区三区| 7777精品伊人久久久大香线蕉经典版下载| 久久人人97超碰com| 亚洲福利国产精品| 99久久99久久精品免费观看| 精品国产91久久久久久久妲己| 亚洲综合自拍偷拍| 成人av电影免费在线播放| 欧美成人官网二区| 日韩电影网1区2区| 欧美日韩一区二区三区四区五区| 亚洲欧美一区二区在线观看| 福利91精品一区二区三区| 日韩免费性生活视频播放| 日韩国产欧美在线观看| 91福利社在线观看| 亚洲影视在线观看| a美女胸又www黄视频久久| 国产欧美一区二区精品忘忧草 | 欧美日韩国产美女| 亚洲欧美日韩在线| www.性欧美| 日韩理论片一区二区| 成人av在线资源| 国产精品久久久久久久久免费桃花 | av网站一区二区三区| 精品剧情在线观看| 精品一区二区三区日韩| 精品久久免费看| 麻豆国产欧美日韩综合精品二区| 91精品国产麻豆国产自产在线| 午夜在线电影亚洲一区| 欧美卡1卡2卡| 日本一不卡视频| 日韩视频一区二区三区 | 亚洲综合一区二区| 91久久精品一区二区| 一级中文字幕一区二区| 欧美午夜影院一区| 国产精华液一区二区三区| 欧美国产精品劲爆| 91在线无精精品入口| 亚洲精品你懂的| 欧美日韩一级黄| 青青草精品视频| 亚洲精品一区二区三区四区高清 | 97se亚洲国产综合自在线不卡| 亚洲激情一二三区| 日韩三级电影网址| 国产成人精品免费网站| 亚洲日本丝袜连裤袜办公室| 欧美精品777| 国产乱子轮精品视频| 中文字幕一区二区三区在线不卡 | 亚洲综合色视频| 欧美顶级少妇做爰| 国产一区二区剧情av在线| 一区免费观看视频| 欧美一级二级在线观看| 成人免费av网站| 亚洲v中文字幕| 久久婷婷久久一区二区三区| 99久久精品国产麻豆演员表| 青娱乐精品在线视频| 国产日韩av一区| 欧美精品久久久久久久多人混战| 狠狠色综合色综合网络| 亚洲精品欧美综合四区| 久久综合久久99| 在线亚洲一区二区| 国产精品66部| 亚洲18女电影在线观看| 中文字幕精品—区二区四季| 欧美高清视频www夜色资源网| 国产成人午夜99999| 日韩av午夜在线观看| 亚洲欧美综合色| 亚洲精品一区二区三区福利| 538prom精品视频线放| www.欧美亚洲| 久久99精品一区二区三区 | 91免费看视频| 国产一区二区三区久久悠悠色av| 亚洲资源中文字幕| 国产精品第一页第二页第三页| 日韩欧美色综合| 欧美性猛片xxxx免费看久爱| 成人蜜臀av电影| 国产一区二区三区美女| 日本特黄久久久高潮| 亚洲国产成人av网| 亚洲另类春色国产| 国产精品黄色在线观看| 久久亚洲捆绑美女| 欧美大片在线观看一区二区| 欧美电影一区二区| 欧美三级一区二区| 91女厕偷拍女厕偷拍高清| 成人aa视频在线观看| 国产美女精品一区二区三区| 久久精品国产99久久6| 天堂一区二区在线| 亚洲永久精品大片| 亚洲一区二区综合| 亚洲国产综合在线| 久久99精品国产.久久久久久| 五月天一区二区| 午夜影院久久久| 日韩高清在线一区| 视频一区二区三区在线| 视频在线观看一区二区三区| 五月天一区二区三区| 午夜a成v人精品| 蜜臀va亚洲va欧美va天堂| 青青草原综合久久大伊人精品 | 精品第一国产综合精品aⅴ| 日韩欧美一区二区不卡| 欧美mv和日韩mv国产网站| 欧美岛国在线观看| 欧美成人女星排行榜| 久久久99精品免费观看| 国产欧美精品一区二区三区四区| 亚洲国产电影在线观看| 中文字幕国产一区| 亚洲欧美日韩国产综合| 一区二区三区中文字幕电影| 午夜精品一区二区三区三上悠亚 | 午夜精品久久久久久久99樱桃| 亚洲国产日韩av| 六月丁香婷婷久久| 国产美女娇喘av呻吟久久| 波多野结衣中文字幕一区| 日本国产一区二区| 欧美猛男男办公室激情| 精品少妇一区二区三区免费观看 | 99久久婷婷国产综合精品电影| 91激情在线视频| 在线综合+亚洲+欧美中文字幕| 久久综合色鬼综合色| 亚洲视频中文字幕| 日本不卡在线视频| 成人性生交大片免费看中文网站 | 大桥未久av一区二区三区中文| 95精品视频在线| 日韩情涩欧美日韩视频| 日韩电影免费在线看| 不卡的电视剧免费网站有什么| 欧美日韩激情一区二区三区| 久久青草国产手机看片福利盒子 | 色菇凉天天综合网| 欧美一区日本一区韩国一区| 久久久久久97三级| 亚洲资源在线观看| 国产丶欧美丶日本不卡视频| 欧美在线免费观看视频| 国产日韩精品一区二区浪潮av| 亚洲最新在线观看| 国产高清视频一区| 欧美老女人第四色| 中文字幕一区在线| 久久99精品久久只有精品| 欧洲一区二区av| 国产精品女人毛片| 日韩成人dvd| 欧美视频三区在线播放| 国产精品水嫩水嫩| 美腿丝袜亚洲综合| 欧美在线一区二区| 国产精品国产三级国产普通话蜜臀| 日本不卡1234视频| 日本丰满少妇一区二区三区| 久久久精品一品道一区| 欧美bbbbb| 欧美日韩免费不卡视频一区二区三区| 国产女主播视频一区二区| 裸体健美xxxx欧美裸体表演| 日本高清成人免费播放| 亚洲欧洲精品成人久久奇米网| 国产精品影音先锋| 日韩你懂的在线播放| 日韩激情av在线| 欧洲国内综合视频| 亚洲美女淫视频| 99在线视频精品| 中文字幕不卡三区| 成人午夜免费电影| 国产偷国产偷精品高清尤物| 国产高清视频一区| 国产欧美在线观看一区| 国产不卡免费视频| 久久综合九色综合欧美98| 久久爱另类一区二区小说|