Function at 0x40aff3
Capabilities:
Get socket status

Disassembly:
mov eax, 0x45ea60
call fcn.0045d320
sub esp, 0x21c
push ebx
push esi
mov esi, ecx
push edi
push dword [esi + 4]
push dword [esi]
push str.CReTranslator::DoSmart__0_solid_X__child_X
push 0x47a230
call fcn.0041158a
add esp, 0x10
xor edi, edi
lea ecx, [ebp - 0x20]
mov dword [esi + 0xc], edi
push 0x4000
mov dword [esi + 0x10], edi
mov byte [esi + 8], 1
mov byte [esi + 0x3c], 1
mov byte [esi + 0x3d], 1
mov byte [esi + 0x3e], 1
call fcn.00411c93
mov dword [ebp - 4], edi
xor edi, edi
cmp byte [esi + 0x3e], 0
mov dword [ebp - 0x124], edi
mov dword [ebp - 0x228], edi
je 0x40b05c
mov eax, dword [esi]
mov dword [ebp - 0x124], 1
mov dword [ebp - 0x120], eax
mov edx, dword [esi + 4]
cmp edx, edi
je 0x40b0a1
xor eax, eax
cmp dword [ebp - 0x124], edi
jbe 0x40b083
lea ecx, [ebp - 0x120]
cmp dword [ecx], edx
je 0x40b083
inc eax
add ecx, 4
cmp eax, dword [ebp - 0x124]
jb 0x40b073
cmp eax, dword [ebp - 0x124]
jne 0x40b0a1
cmp dword [ebp - 0x124], 0x40
jae 0x40b0a1
mov dword [ebp + eax*4 - 0x120], edx
inc dword [ebp - 0x124]
mov eax, dword [esi + 0x34]
sub eax, dword [esi + 0x38]
je 0x40b0bb
mov eax, dword [esi]
mov dword [ebp - 0x228], 1
mov dword [ebp - 0x224], eax
mov eax, dword [esi + 0x20]
lea ebx, [esi + 0x14]
sub eax, dword [ebx + 0x10]
je 0x40b10a
cmp edx, edi
je 0x40b10a
xor eax, eax
cmp dword [ebp - 0x228], edi
jbe 0x40b0ea
lea ecx, [ebp - 0x224]
cmp dword [ecx], edx
je 0x40b0ea
inc eax
add ecx, 4
cmp eax, dword [ebp - 0x228]
jb 0x40b0da
cmp eax, dword [ebp - 0x228]
jne 0x40b108
cmp dword [ebp - 0x228], 0x40
jae 0x40b108
mov dword [ebp + eax*4 - 0x224], edx
inc dword [ebp - 0x228]
xor edi, edi
push edi
lea eax, [ebp - 0x228]
push edi
push eax
lea eax, [ebp - 0x124]
push eax
push edi
call dword [sym.imp.WS2_32.dll_select]
cmp eax, edi
jle 0x40b2e6
cmp eax, 4
jg 0x40b2e6
cmp byte [esi + 0x3e], 0
je 0x40b19e
lea eax, [ebp - 0x124]
push eax
push dword [esi]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x40b19e
mov ecx, dword [ebx + 0xc]
mov eax, dword [ebx]
add ecx, 0x4000
push ecx
mov ecx, ebx
call dword [eax + 4]
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x14]
push eax
push dword [esi]
call fcn.0040b320
pop ecx
cmp eax, edi
pop ecx
jle 0x40b198
push eax
mov ecx, esi
call fcn.0040ae3b
cmp byte [esi + 0x3e], 0
jne 0x40b19e
push str.CReTranslator::DoSmart__139_Remote_child_socket_was_closed
push 0x47a230
call fcn.0041158a
pop ecx
pop ecx
mov ecx, esi
call fcn.0040af7f
jmp 0x40b19e
jl 0x40b2b5
mov eax, dword [esi + 4]
cmp eax, edi
je 0x40b207
lea ecx, [ebp - 0x124]
push ecx
push eax
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x40b207
lea ecx, [ebp - 0x20]
call fcn.00412369
push eax
push dword [esi + 4]
call fcn.0040b320
mov edi, eax
pop ecx
test edi, edi
pop ecx
jle 0x40b1e5
push edi
lea ecx, [ebp - 0x20]
call fcn.00412369
push eax
mov ecx, esi
call fcn.0040af18
add dword [esi + 0x10], edi
jmp 0x40b207
jge 0x40b207
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.CReTranslator::DoSmart__165_child_socket_was_closed__error_d
push 0x47a230
call fcn.0041158a
add esp, 0xc
mov ecx, esi
call fcn.0040af7f
cmp byte [esi + 0x3d], 0
je 0x40b23e
mov eax, 0x80
cmp dword [esi + 0xc], eax
jbe 0x40b23e
cmp dword [esi + 0x10], eax
jbe 0x40b23e
and byte [esi + 0x3d], 0
push 0x28e
lea ecx, [esi + 0x28]
call fcn.00411d15
push str.CReTranslator::DoSmart__170_sent_request_for_direct_transfer
push 0x47a230
call fcn.0041158a
pop ecx
pop ecx
mov eax, dword [esi + 4]
test eax, eax
je 0x40b272
push ebx
push eax
call fcn.0040b36f
pop ecx
test al, al
pop ecx
jne 0x40b272
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.CReTranslator::DoSmart__166_child_socket_was_closed__error_d
push 0x47a230
call fcn.0041158a
add esp, 0xc
mov ecx, esi
call fcn.0040af7f
lea edi, [esi + 0x28]
push edi
push dword [esi]
call fcn.0040b36f
pop ecx
test al, al
pop ecx
je 0x40b2c3
mov al, byte [esi + 0x3e]
test al, al
jne 0x40b2a0
cmp dword [esi + 4], 0
jne 0x40b298
mov ecx, dword [edi + 0xc]
sub ecx, dword [edi + 0x10]
je 0x40b2de
test al, al
je 0x40b036
cmp byte [esi + 0x3c], 0
jne 0x40b036
cmp byte [esi + 0x3d], 0
je 0x40b2e2
jmp 0x40b036
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.CReTranslator::DoSmart__159_solid_socket_read_error_d
jmp 0x40b2cf
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.CReTranslator::DoSmart__159_solid_socket_send_error_d
push 0x47a230
call fcn.00411572
add esp, 0xc
jmp 0x40b300
push 2
jmp 0x40b302
push 3
jmp 0x40b302
push eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.DoSmart__1_error_d__d
push 0x47a230
call fcn.00411572
add esp, 0x10
push 1
or dword [ebp - 4], 0xffffffff
pop esi
lea ecx, [ebp - 0x20]
call fcn.00411cb9
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret