From f39767f1f24ba2da4134905a5b40c399e0ac2a4b Mon Sep 17 00:00:00 2001 From: hidnplayr Date: Tue, 15 Oct 2013 16:18:58 +0000 Subject: [PATCH] Bugfix in SOCKET_connect git-svn-id: svn://kolibrios.org@4035 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/trunk/network/IPv4.inc | 7 ++++--- kernel/trunk/network/tcp_usreq.inc | 4 ++-- kernel/trunk/network/udp.inc | 4 ++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/kernel/trunk/network/IPv4.inc b/kernel/trunk/network/IPv4.inc index fd770848ef..70805df030 100644 --- a/kernel/trunk/network/IPv4.inc +++ b/kernel/trunk/network/IPv4.inc @@ -922,10 +922,10 @@ IPv4_get_frgmnt_num: align 4 IPv4_connect: - pusha + push eax edx lea ecx, [eax + SOCKET.mutex] call mutex_lock - popa + pop edx eax ; Fill in local IP cmp [eax + IP_SOCKET.LocalIP], 0 @@ -937,8 +937,9 @@ IPv4_connect: pushd [edx + 4] pop [eax + IP_SOCKET.RemoteIP] +; Set up data receiving queue push eax - init_queue (eax + SOCKET_QUEUE_LOCATION) ; Set up data receiving queue + init_queue (eax + SOCKET_QUEUE_LOCATION) pop eax lea ecx, [eax + SOCKET.mutex] diff --git a/kernel/trunk/network/tcp_usreq.inc b/kernel/trunk/network/tcp_usreq.inc index be947e710c..c1b45975f3 100644 --- a/kernel/trunk/network/tcp_usreq.inc +++ b/kernel/trunk/network/tcp_usreq.inc @@ -89,10 +89,10 @@ TCP_connect: test [eax + SOCKET.state], SS_ISCONNECTED jnz .eisconn - push eax + push eax edx lea ecx, [eax + SOCKET.mutex] call mutex_lock - pop eax + pop edx eax ; Fill in local IP cmp [eax + IP_SOCKET.LocalIP], 0 diff --git a/kernel/trunk/network/udp.inc b/kernel/trunk/network/udp.inc index 93874473ca..3485dd0a93 100644 --- a/kernel/trunk/network/udp.inc +++ b/kernel/trunk/network/udp.inc @@ -327,10 +327,10 @@ UDP_connect: call UDP_disconnect @@: - push eax + push eax edx lea ecx, [eax + SOCKET.mutex] call mutex_lock - pop eax + pop edx eax ; Fill in local IP cmp [eax + IP_SOCKET.LocalIP], 0