Function at 0x140070ef0
Capabilities:
Get socket status

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x390]
sub rsp, 0x490
mov rax, qword [0x1400db748]
xor rax, rsp
mov qword [rbp + 0x380], rax
mov eax, dword [rbp + 0x3f0]
movzx r12d, r9b
mov rsi, qword [rbp + 0x3f8]
mov r14, rcx
mov dword [rsp + 0x30], eax
mov rax, qword [rbp + 0x400]
mov qword [rsp + 0x50], rax
test rsi, rsi
je 0x140070f4c
mov qword [rsp + 0x38], rsi
jmp 0x140070f54
mov r15, qword [rcx]
mov qword [rsp + 0x38], r15
xor r15d, r15d
mov qword [rsp + 0x4e0], rbx
movsxd r13, edx
mov edi, r15d
test edx, edx
jle 0x140070f94
mov ebx, r15d
nop dword [rax]
test r12b, r12b
je 0x140070f8a
mov rcx, qword [r14 + rbx*8]
mov rcx, qword [rcx + 0x78]
call fcn.1400753c0
test eax, eax
jne 0x1400710ed
inc edi
inc rbx
cmp rbx, r13
jl 0x140070f70
mov edi, dword [rsp + 0x30]
mov eax, 0x10624dd3
imul edi
mov ecx, edi
sar edx, 6
mov eax, edx
shr eax, 0x1f
add edx, eax
imul eax, edx, 0x3e8
mov dword [rsp + 0x40], edx
sub ecx, eax
imul eax, ecx, 0x3e8
mov dword [rsp + 0x34], eax
mov dword [rsp + 0x48], edx
mov ebx, 1
mov dword [rsp + 0x4c], eax
mov r8d, r15d
mov dword [rsp + 0x60], r15d
mov r9d, r15d
mov dword [rbp + 0x170], r15d
mov r10, r15
test r13, r13
jle 0x14007109d
nop dword [rax]
mov edx, r15d
test r8d, r8d
je 0x140071010
mov rax, qword [r14 + r10*8]
movsxd rcx, dword [rax + 0x70]
mov eax, edx
cmp qword [rsp + rax*8 + 0x68], rcx
je 0x140071010
inc edx
cmp edx, r8d
jb 0x140071000
cmp edx, r8d
jne 0x140071037
cmp r8d, 0x40
jae 0x140071037
mov rax, qword [r14 + r10*8]
movsxd rcx, dword [rax + 0x70]
mov eax, edx
mov qword [rsp + rax*8 + 0x68], rcx
mov r8d, dword [rsp + 0x60]
inc r8d
mov dword [rsp + 0x60], r8d
mov eax, r15d
test r9d, r9d
je 0x140071063
mov rcx, qword [r14 + r10*8]
movsxd rdx, dword [rcx + 0x70]
nop word [rax + rax]
mov ecx, eax
cmp qword [rbp + rcx*8 + 0x178], rdx
je 0x140071063
inc eax
cmp eax, r9d
jb 0x140071050
cmp eax, r9d
jne 0x140071091
cmp r9d, 0x40
jae 0x140071091
mov rcx, qword [r14 + r10*8]
movsxd rdx, dword [rcx + 0x70]
mov ecx, eax
mov qword [rbp + rcx*8 + 0x178], rdx
mov r9d, dword [rbp + 0x170]
inc r9d
mov dword [rbp + 0x170], r9d
inc r10
cmp r10, r13
jl 0x140070ff0
test rsi, rsi
je 0x140071103
mov rcx, rsi
call fcn.14006b930
test edi, edi
lea rax, [rsp + 0x48]
lea r8, [rsp + 0x60]
mov ecx, ebx
cmovs rax, r15
lea rdx, [rsp + 0x60]
test r12b, r12b
mov qword [rsp + 0x20], rax
lea r9, [rbp + 0x170]
cmovne r8, r15
cmove rdx, r15
call qword [sym.imp.WS2_32.dll_select]
mov rcx, rsi
mov edi, eax
call fcn.14006b770
jmp 0x140071171
movsxd rax, edi
mov rcx, qword [r14 + rax*8]
mov rax, qword [rsp + 0x50]
mov qword [rax], rcx
xor eax, eax
jmp 0x140071462
lea rbx, [r13 - 1]
test rbx, rbx
js 0x14007111f
nop dword [rax]
mov rcx, qword [r14 + rbx*8]
call fcn.14006b930
sub rbx, 1
jns 0x140071110
test edi, edi
lea rax, [rsp + 0x48]
lea r8, [rsp + 0x60]
mov ecx, 1
cmovs rax, r15
lea rdx, [rsp + 0x60]
test r12b, r12b
mov qword [rsp + 0x20], rax
lea r9, [rbp + 0x170]
cmovne r8, r15
cmove rdx, r15
call qword [sym.imp.WS2_32.dll_select]
mov rbx, r15
mov edi, eax
test r13, r13
jle 0x140071171
mov rcx, qword [r14 + rbx*8]
call fcn.14006b770
inc rbx
cmp rbx, r13
jl 0x140071160
cmp edi, 0xffffffff
jne 0x140071253
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
cmp eax, 4
jne 0x1400711d2
mov rcx, qword [rsp + 0x38]
call fcn.14006b3e0
mov rcx, qword [rsp + 0x38]
mov ebx, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, ebx
call fcn.14001bf60
lea rdx, str.AsyncTCPSocketPollWork
lea rcx, str._s:_Socket_interrupted_by_a_signal._n
call fcn.14001bf60
mov edx, dword [rsp + 0x40]
mov eax, dword [rsp + 0x34]
mov edi, dword [rsp + 0x30]
jmp 0x140070fc1
test rsi, rsi
je 0x1400711df
mov dword [rsi + 0x80], edi
jmp 0x140071202
test r13, r13
jle 0x140071202
nop dword [rax]
nop dword [rax + rax]
mov rax, qword [r14 + r15*8]
inc r15
mov dword [rax + 0x80], edi
cmp r15, r13
jl 0x1400711f0
mov rcx, qword [rsp + 0x38]
call fcn.14006b3e0
mov rcx, qword [rsp + 0x38]
mov ebx, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, ebx
call fcn.14001bf60
mov ecx, edi
call fcn.140013400
mov r9, rax
lea rdx, str.AsyncTCPSocketPollWork
mov r8d, edi
lea rcx, str._s:_Failed_with_error__d:__s_n
call fcn.14001bf60
mov eax, 1
jmp 0x140071462
test edi, edi
je 0x140071423
xor bl, bl
mov r12d, 1
test r13, r13
jle 0x1400713d1
mov rdi, r15
nop
mov rax, qword [r14 + rdi*8]
lea rdx, [rbp + 0x170]
movsxd rcx, dword [rax + 0x70]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
movzx ebx, bl
cmovne ebx, r12d
inc rdi
cmp rdi, r13
jl 0x140071270
test bl, bl
je 0x14007139d
mov dword [rsp + 0x30], r15d
mov dword [rsp + 0x34], 4
nop word [rax + rax]
mov rax, qword [r14 + r15*8]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov r8d, 0x1007
movsxd rcx, dword [rax + 0x70]
lea rax, [rsp + 0x34]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x140071330
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x140071389
mov rax, qword [r14 + r15*8]
mov dword [rax + 0x80], ecx
mov rbx, qword [r14 + r15*8]
mov rcx, rbx
call fcn.14006b3e0
mov rcx, rbx
mov edi, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, edi
call fcn.14001bf60
mov ecx, dword [rsp + 0x30]
call fcn.140013400
mov r8d, dword [rsp + 0x30]
lea rcx, str._s:_Socket_error_lookup_returned__d:__s_n
jmp 0x14007137a
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [r14 + r15*8]
mov esi, eax
mov dword [rcx + 0x80], eax
mov rbx, qword [r14 + r15*8]
mov rcx, rbx
call fcn.14006b3e0
mov rcx, rbx
mov edi, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, edi
call fcn.14001bf60
mov ecx, esi
call fcn.140013400
mov r8d, esi
lea rcx, str._s:_Last_socket_error__d:__s_n
mov r9, rax
lea rdx, str.AsyncTCPSocketPollWork
call fcn.14001bf60
inc r15
cmp r15, r13
jl 0x1400712b0
mov eax, r12d
jmp 0x140071462
test r13, r13
jle 0x1400713d1
mov rbx, r15
nop word [rax + rax]
mov rax, qword [r14 + rbx*8]
lea rdx, [rsp + 0x60]
movsxd rcx, dword [rax + 0x70]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x140071410
inc r15d
inc rbx
cmp rbx, r13
jl 0x1400713b0
mov rcx, qword [rsp + 0x38]
call fcn.14006b3e0
mov rcx, qword [rsp + 0x38]
mov ebx, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, ebx
call fcn.14001dba0
lea rdx, str.AsyncTCPSocketPollWork
lea rcx, str._s:_Failed_to_return_a_ready_socket._n
call fcn.14001dba0
mov eax, r12d
jmp 0x140071462
movsxd rax, r15d
mov rcx, qword [r14 + rax*8]
mov rax, qword [rsp + 0x50]
mov qword [rax], rcx
xor eax, eax
jmp 0x140071462
mov rcx, qword [rsp + 0x38]
call fcn.14006b3e0
mov rcx, qword [rsp + 0x38]
mov ebx, eax
call fcn.14006baf0
mov edx, eax
lea rcx, [0x1400af598]
mov r8d, ebx
call fcn.14001bf60
lea rdx, str.AsyncTCPSocketPollWork
lea rcx, str._s:_Timeout_waiting_for_a_ready_socket._n
call fcn.14001bf60
mov eax, 2
mov rbx, qword [rsp + 0x4e0]
mov rcx, qword [rbp + 0x380]
xor rcx, rsp
call fcn.14006a480
add rsp, 0x490
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret