From 2861c164de503665b2562204acfe9cdfa74e26f3 Mon Sep 17 00:00:00 2001 From: hidnplayr Date: Fri, 28 Jan 2011 16:16:31 +0000 Subject: [PATCH] Small update in TCP_input git-svn-id: svn://kolibrios.org@1772 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/branches/net/network/tcp_input.inc | 35 ++++++++++++++++++----- 1 file changed, 28 insertions(+), 7 deletions(-) diff --git a/kernel/branches/net/network/tcp_input.inc b/kernel/branches/net/network/tcp_input.inc index 363823d03d..34f0d99637 100644 --- a/kernel/branches/net/network/tcp_input.inc +++ b/kernel/branches/net/network/tcp_input.inc @@ -1101,7 +1101,7 @@ align 4 @@: - + ;; TODO: use zero flag as 'ourfinisacked' @@ -1126,22 +1126,43 @@ align 4 dd .ack_tw ;TCB_TIMED_WAIT - .ack_fw1: ; 963 + .ack_fw1: + jz .ack_processed + test [ebx + SOCKET.state], SO_CANTRCVMORE + jnz @f + ;;soisdisconnected(ebx) + mov [ebx + TCP_SOCKET.timer_timed_wait], TCP_time_max_idle + @@: + mov [ebx + TCP_SOCKET.t_state], TCB_FIN_WAIT_2 jmp .ack_processed - .ack_c: ; 958 + .ack_c: + jz .ack_processed + + mov [ebx + TCP_SOCKET.t_state], TCB_TIMED_WAIT + call TCP_cancel_timers + mov [ebx + TCP_SOCKET.timer_timed_wait], 2 * TCP_time_MSL + ;;soisdisconnected(ebx) jmp .ack_processed - .ack_la: ; 999 - jmp .ack_processed + .ack_la: + jz .ack_processed + + call TCP_close + jmp .drop + + + .ack_tw: + mov [ebx + TCP_SOCKET.timer_timed_wait], 2 * TCP_time_MSL + jmp .drop_after_ack + + - .ack_tw: ; 1010 - jmp .ack_processed