Function at 0x4032e0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov esi, dword [ebp + 8]
mov edx, dword [esi + 8]
mov ecx, dword [edx + 0x40]
test ecx, 0x200000
jne 0x403635
mov dword [ebp - 0x10], 0
shr ecx, 0xb
xor eax, eax
xor edi, edi
cmp dword [edx + 0x24], 0
setne al
and ecx, 1
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], ecx
jne 0x403553
mov ebx, dword [edx + 4]
mov eax, dword [esi + 4]
test ebx, ebx
mov dword [ebp - 0x1c], eax
jne 0x403567
lea eax, [esi + 0xc]
mov dword [ebp - 0x20], eax
mov dword [esp], edx
mov dword [esp + 4], eax
call fcn.00406550
mov edx, dword [esi + 0xc]
mov dword [edx + 0x44], 1
nop
mov dword [esp + 4], edx
mov dword [esp], esi
call fcn.004029d0
mov edx, dword [esi + 0xc]
mov eax, dword [edx + 0x2c]
cmp eax, 0xffffffff
je 0x403543
mov ecx, dword [0x413084]
test ecx, ecx
jne 0x40368f
mov ecx, dword [esi + 8]
test byte [ecx + 0x42], 0x10
je 0x403580
mov ebx, dword [0x413008]
test ebx, ebx
jne 0x403580
mov eax, dword [edx + 0x78]
mov edi, 1
mov dword [ecx + 0x78], eax
mov eax, dword [edx + 0x7c]
mov dword [ecx + 0x7c], eax
mov eax, dword [edx + 0x80]
mov dword [ecx + 0x80], eax
mov eax, dword [edx + 0x84]
mov dword [ecx + 0x84], eax
mov eax, dword [esi]
dec eax
mov dword [esi], eax
test eax, eax
je 0x403613
mov eax, dword [esi + 0xc]
add eax, 0x78
mov dword [esp + 4], eax
mov eax, dword [esi + 8]
add eax, 0x78
mov dword [esp], eax
call fcn.00407890
test eax, eax
je 0x4035a8
lea esi, [esi]
mov dword [esp], 0x1c
call fcn.00409750
mov edx, dword [esi + 0xc]
mov ebx, eax
mov eax, dword [edx + 0x78]
mov dword [ebx], eax
mov eax, dword [edx + 0x7c]
mov dword [ebx + 4], eax
mov eax, dword [edx + 0x80]
mov dword [ebx + 8], eax
mov eax, dword [edx + 0x84]
mov dword [ebx + 0x18], 0
mov dword [ebx + 0xc], eax
mov dword [esp], 0x413004
call sub.cygwin1.dll_pthread_mutex_lock
mov eax, dword [0x413008]
mov dword [esp + 4], eax
mov eax, dword [esi + 0xc]
add eax, 0x78
mov dword [esp], eax
call fcn.00402660
test eax, eax
mov ecx, eax
je 0x403645
mov eax, dword [eax + 0x10]
mov edx, dword [esi + 0xc]
mov dword [ebx + 0x10], eax
mov eax, dword [ecx + 0x10]
mov dword [edx + 0x18], eax
mov dword [esp], ebx
mov ecx, 0x413008
mov dword [esp + 4], ecx
call fcn.00402550
mov dword [esp], 0x413004
call fcn.0040d248
mov dword [ebp - 0x10], 0
mov eax, dword [esi + 8]
mov eax, dword [eax + 0x40]
test al, 2
jne 0x4034e0
test ah, 0x40
jne 0x4034e0
mov edx, dword [ebp - 0x14]
test edx, edx
jne 0x4034c3
xor eax, eax
mov dword [esp + 0xc], eax
mov eax, 0x18
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 4], eax
mov eax, dword [esi + 0xc]
mov eax, dword [eax + 0x2c]
mov dword [esp], eax
call sub.cygwin1.dll_recv
test eax, eax
jle 0x4034e0
mov eax, dword [ebp - 0x1c]
mov dword [esp + 8], eax
lea eax, [ebp - 0x10]
mov dword [esp + 4], eax
mov eax, dword [esi + 0xc]
mov dword [esp], eax
call fcn.00407250
lea esi, [esi]
mov eax, dword [ebp - 0x10]
test eax, eax
jne 0x4035e0
mov eax, dword [esi + 0xc]
mov dword [esp], eax
call fcn.004091d0
mov eax, dword [ebp - 0x14]
test eax, eax
jne 0x4035c7
mov edx, dword [esi + 8]
test byte [edx + 0x42], 0x10
jne 0x40350c
dec dword [esi]
mov eax, dword [ebp - 0x20]
mov dword [esp], edx
mov dword [esp + 4], eax
call fcn.00406550
mov edx, dword [esi + 0xc]
mov dword [edx + 0x44], 1
mov eax, dword [0x413084]
test eax, eax
jne 0x403543
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x403350
mov eax, dword [esi]
test eax, eax
jg 0x403350
mov dword [esp], edx
call fcn.004066e0
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esi + 4]
mov ebx, dword [edx + 4]
add eax, 0xc
mov dword [ebp - 0x1c], eax
test ebx, ebx
je 0x403333
mov dword [esp], edx
call fcn.00407700
mov edx, dword [esi + 8]
mov edi, 1
jmp 0x403333
test edi, edi
je 0x4033f0
mov eax, dword [esi + 0xc]
add eax, 0x78
mov dword [esp + 4], eax
mov eax, dword [esi + 8]
add eax, 0x78
mov dword [esp], eax
call fcn.00407890
test eax, eax
jne 0x4033f0
mov eax, dword [esi + 0xc]
mov eax, dword [eax + 0x2c]
mov dword [esp], eax
call sub.cygwin1.dll_close
mov eax, dword [esi + 8]
test byte [eax + 0x41], 8
jne 0x4035fc
mov edx, dword [esi + 0xc]
jmp 0x403525
mov eax, dword [esi + 8]
mov dword [eax + 0x2c], 0xffffffff
mov dword [esp], esi
call fcn.00402790
jmp 0x403501
mov dword [esp], eax
call fcn.004024a0
mov edx, dword [ebp - 0x10]
cmp dword [edx + 0x4c], 1
je 0x40362a
mov eax, dword [esi + 0xc]
mov dword [eax + 0x20], edx
jmp 0x4034eb
mov dword [eax + 0x2c], 0xffffffff
mov dword [esp], esi
call fcn.00402790
mov edx, dword [esi + 0xc]
jmp 0x403525
mov dword [esp], 0
call fcn.00409420
mov dword [esi], 1
jmp 0x4033ca
mov eax, dword [esi + 0xc]
mov dword [eax + 0x1c], edx
jmp 0x4034eb
mov dword [esp], esi
call fcn.00402bc0
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esi + 0xc]
mov dword [eax + 0x24], 0
mov dword [esp], 0x41307c
call sub.cygwin1.dll_pthread_mutex_lock
mov eax, dword [0x413080]
dec eax
mov dword [esp + 4], eax
mov dword [0x413080], eax
mov eax, dword [esi + 0xc]
mov dword [esp], eax
call fcn.00404420
mov dword [ebx + 0x10], eax
mov edx, dword [esi + 0xc]
mov dword [edx + 0x18], eax
mov dword [esp], 0x41307c
call fcn.0040d248
jmp 0x403461
mov dword [esp], eax
call sub.cygwin1.dll_close
mov edx, dword [esi + 0xc]
mov dword [esp], edx
call fcn.004066e0
jmp 0x40354b