Function at 0x41d0f0
Capabilities:
Get socket status

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x36c
mov eax, dword [esp + 0x380]
mov dword [esp + 0x54], 0
lea edi, [esp + 0x54]
test eax, eax
jle 0x41d194
mov ebx, dword [esp + 0x384]
mov esi, dword [esp + 0x380]
mov edx, 1
lea edi, [esp + 0x54]
lea eax, [ebx + esi*4]
mov ecx, dword [ebx]
mov dword [esp + 0x34], eax
xor eax, eax
mov dword [esp + eax*4 + 0x58], ecx
add ebx, 4
cmp dword [esp + 0x34], ebx
je 0x41d190
mov ecx, dword [ebx]
xor eax, eax
jmp 0x41d157
add eax, 1
cmp edx, eax
je 0x41d15d
cmp dword [edi + eax*4 + 4], ecx
jne 0x41d150
cmp edx, 0x40
mov dword [esp + 0x2c], ecx
setne cl
cmp edx, eax
mov dword [esp + 0x30], eax
mov ebp, ecx
sete cl
mov esi, ecx
mov ecx, ebp
mov eax, esi
test cl, al
je 0x41d13b
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x30]
add edx, 1
jmp 0x41d137
mov dword [esp + 0x54], edx
mov eax, dword [esp + 0x388]
lea ebp, [esp + 0x158]
mov dword [esp + 0x158], 0
test eax, eax
jle 0x41d243
mov ebx, dword [esp + 0x38c]
mov esi, dword [esp + 0x388]
mov dword [esp + 0x38], edi
mov edx, 1
lea ebp, [esp + 0x158]
lea eax, [ebx + esi*4]
mov ecx, dword [ebx]
mov dword [esp + 0x34], eax
xor eax, eax
mov dword [esp + eax*4 + 0x15c], ecx
add ebx, 4
cmp dword [esp + 0x34], ebx
je 0x41d238
mov ecx, dword [ebx]
xor eax, eax
jmp 0x41d1ff
add eax, 1
cmp edx, eax
je 0x41d205
cmp dword [ebp + eax*4 + 4], ecx
jne 0x41d1f8
cmp edx, eax
mov dword [esp + 0x30], ecx
sete cl
cmp edx, 0x40
mov dword [esp + 0x2c], eax
mov edi, ecx
setne cl
mov esi, ecx
mov ecx, edi
mov eax, esi
test cl, al
je 0x41d1e5
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x30]
add edx, 1
jmp 0x41d1de
mov dword [esp + 0x158], edx
mov edi, dword [esp + 0x38]
mov eax, dword [esp + 0x390]
lea ebx, [esp + 0x25c]
mov dword [esp + 0x25c], 0
test eax, eax
jle 0x41d303
mov esi, dword [esp + 0x394]
mov ebx, dword [esp + 0x390]
mov dword [esp + 0x38], edi
mov edx, 1
mov dword [esp + 0x3c], ebp
lea eax, [esi + ebx*4]
mov ecx, dword [esi]
lea ebx, [esp + 0x25c]
mov dword [esp + 0x34], eax
xor eax, eax
mov dword [esp + eax*4 + 0x260], ecx
mov dword [esp + 0x2c], ebx
add esi, 4
cmp dword [esp + 0x34], esi
je 0x41d2f0
mov ecx, dword [esi]
mov ebx, dword [esp + 0x2c]
xor eax, eax
jmp 0x41d2b7
add eax, 1
cmp edx, eax
je 0x41d2bd
cmp dword [ebx + eax*4 + 4], ecx
jne 0x41d2b0
cmp edx, 0x40
mov dword [esp + 0x2c], ebx
setne bl
cmp edx, eax
mov dword [esp + 0x30], ecx
mov ebp, ebx
sete bl
mov edi, ebx
mov ebx, ebp
mov ecx, edi
test bl, cl
je 0x41d29c
mov ecx, dword [esp + 0x30]
mov ebx, dword [esp + 0x2c]
add edx, 1
jmp 0x41d291
mov edi, dword [esp + 0x38]
mov ebp, dword [esp + 0x3c]
mov dword [esp + 0x25c], edx
mov ebx, dword [esp + 0x2c]
mov esi, dword [esp + 0x398]
xor eax, eax
test esi, esi
js 0x41d34e
mov eax, 0x10624dd3
imul dword [esp + 0x398]
mov ecx, dword [esp + 0x398]
sar ecx, 0x1f
mov eax, edx
sar eax, 6
sub eax, ecx
imul edx, eax, 0x3e8
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x398]
sub eax, edx
imul eax, eax, 0x3e8
mov dword [esp + 0x50], eax
lea eax, [esp + 0x4c]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], ebx
mov dword [esp + 8], ebp
mov dword [esp + 4], edi
mov dword [esp], 0
call dword [sym.imp.WS2_32.dll_select]
sub esp, 0x14
mov dword [esp + 0x2c], eax
test eax, eax
js 0x41d45e
mov ecx, dword [esp + 0x380]
xor esi, esi
test ecx, ecx
jle 0x41d3ce
mov dword [esp + 0x30], ebp
mov ebp, dword [esp + 0x384]
mov dword [esp + 0x34], ebx
mov ebx, esi
mov esi, dword [esp + 0x380]
nop
mov dword [esp + 4], edi
mov eax, dword [ebp + ebx*4]
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
jne 0x41d3bf
mov dword [ebp + ebx*4], 0
add ebx, 1
cmp esi, ebx
jne 0x41d3a0
mov ebp, dword [esp + 0x30]
mov ebx, dword [esp + 0x34]
mov edx, dword [esp + 0x388]
xor edi, edi
test edx, edx
jle 0x41d418
mov dword [esp + 0x30], ebx
mov esi, dword [esp + 0x388]
mov ebx, dword [esp + 0x38c]
lea esi, [esi]
mov dword [esp + 4], ebp
mov eax, dword [ebx + edi*4]
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
jne 0x41d40d
mov dword [ebx + edi*4], 0
add edi, 1
cmp esi, edi
jne 0x41d3f0
mov ebx, dword [esp + 0x30]
mov eax, dword [esp + 0x390]
xor edi, edi
test eax, eax
jle 0x41d45e
mov esi, dword [esp + 0x390]
mov ebp, dword [esp + 0x394]
lea esi, [esi]
nop
mov dword [esp + 4], ebx
mov eax, dword [ebp + edi*4]
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
jne 0x41d457
mov dword [ebp + edi*4], 0
add edi, 1
cmp esi, edi
jne 0x41d438
mov eax, dword [esp + 0x2c]
add esp, 0x36c
pop ebx
pop esi
pop edi
pop ebp
ret