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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x7482e8
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x899944]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
cmp dword [ebp + 0x14], 0xabcd0123
jne 0x51572e
mov byte [ebp + 0x10], 1
mov dword [ebp + 0x14], 1
cmp dword [ebp + 8], 0
je 0x515a25
mov ebx, dword [ebp + 0x18]
mov ecx, ebx
call fcn.004a71c0
or esi, 0xffffffff
cmp dword [edi + 0xb4], esi
jne 0x51576e
mov ecx, dword [ebp + 0x1c]
mov eax, dword [ecx]
mov edx, dword [eax + 0x14]
push str.This_socket_is_not_connected
call edx
mov byte [ebx + 0x12], 1
mov word [edi + 0xb0], 0
jmp 0x515a25
cmp byte [edi + 0x11], 0
lea eax, [edi + 0x11]
je 0x51578b
mov ecx, dword [ebp + 0x1c]
mov eax, dword [ecx]
mov edx, dword [eax + 0x14]
push str.Another_thread_is_already_receiving_on_this_socket.
call edx
jmp 0x515a25
cmp byte [edi + 0x12], 0
je 0x5157a7
mov ecx, dword [ebp + 0x1c]
mov eax, dword [ecx]
mov edx, dword [str.Another_thread_is_closing_this_socket.]
mov eax, dword [eax + 0x14]
push edx
call eax
jmp 0x515a25
push eax
lea ecx, [ebp - 0x18]
call fcn.0046e4a0
mov eax, dword [ebp + 0xc]
mov ebx, dword [eax]
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], ebx
mov dword [eax], 0
test ebx, ebx
jne 0x5157ea
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], esi
call fcn.0046e4c0
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
cmp dword [ebp + 0x14], 0
jne 0x5157f7
mov dword [ebp + 0x14], 0xc042c00
mov edx, dword [ebp + 0x18]
mov esi, dword [ebp + 0x1c]
mov eax, dword [edx + 4]
push esi
push eax
lea ecx, [edi + 0x150]
push 0x1000
call fcn.00566620
test al, al
je 0x515830
mov ecx, dword [ebp + 0x18]
mov byte [ecx + 0x11], 1
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.Aborted_by_application_while_download_throttling__2_
mov ecx, esi
call eax
jmp 0x515a16
cmp byte [edi + 0x12], 0
je 0x51584a
mov edx, dword [esi]
mov eax, dword [str.Another_thread_is_closing_this_socket.]
mov edx, dword [edx + 0x14]
push eax
mov ecx, esi
call edx
jmp 0x515a16
cmp dword [edi + 0xb4], 0xffffffff
jne 0x515866
mov eax, dword [esi]
mov edx, dword [eax + 0x14]
push str.The_socket_is_already_closed.__Cannot_recv.
mov ecx, esi
call edx
jmp 0x515a16
cmp ebx, 0x100000
jbe 0x515878
mov dword [ebp - 0x10], 0x100000
mov ebx, dword [ebp - 0x10]
mov byte [ebp + 0x1f], 1
lea esp, [esp]
mov eax, dword [ebp + 8]
mov ecx, dword [edi + 0xb4]
push 0
push ebx
push eax
push ecx
call dword [sym.imp.WS2_32.dll_recv]
mov ebx, eax
test ebx, ebx
jg 0x5158ff
je 0x515973
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x5159ab
cmp byte [ebp + 0x1f], 0
je 0x515a0f
cmp byte [ebp + 0x10], 0
jne 0x515a0f
mov ecx, dword [ebp + 0x18]
push esi
call fcn.004a71f0
test al, al
jne 0x515a16
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x14]
push esi
push edx
push eax
mov ecx, edi
call fcn.00513e90
test al, al
je 0x5159e0
mov byte [ebp + 0x1f], 0
test ebx, ebx
jns 0x515a16
mov ebx, dword [ebp - 0x10]
jmp 0x515880
mov ecx, dword [ebp + 0xc]
lea edx, [ebx - 0x1000]
mov dword [ecx], ebx
push edx
lea ecx, [edi + 0x150]
call fcn.00566820
cmp byte [edi + 0x278], 0
je 0x515930
mov eax, dword [ebp + 0x18]
mov ecx, dword [eax + 4]
push esi
push ecx
push ebx
lea ecx, [edi + 0x20]
call fcn.004a6c80
cmp byte [edi + 0x275], 0
je 0x51594e
mov edx, dword [ebp + 0x18]
mov ecx, dword [edx + 4]
test ecx, ecx
je 0x51594e
mov eax, ebx
cdq
push esi
push edx
push eax
call fcn.00488110
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], 0xffffffff
call fcn.0046e4c0
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
cmp byte [esi + 0xad], 0
je 0x51599a
mov eax, dword [ebp - 0x10]
push eax
push str.maxToReceive
mov ecx, esi
call fcn.00474a80
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.Connection_closed_by_peer.
mov ecx, esi
call eax
push esi
mov ecx, edi
call fcn.005151f0
mov ecx, dword [ebp + 0x18]
mov byte [ecx + 0x13], 1
jmp 0x515a16
mov ecx, esi
call fcn.00474d10
mov edx, dword [ebp - 0x10]
push edx
push str.maxToReceive
mov ecx, esi
call fcn.00474a80
mov eax, dword [esi]
mov edx, dword [eax + 0x14]
push str.Failed_to_receive_data_on_the_TCP_socket
mov ecx, esi
call edx
mov eax, dword [ebp + 0x18]
mov byte [eax + 0x12], 1
mov byte [edi + 0xb0], 0
jmp 0x515a16
mov eax, dword [ebp + 0x18]
cmp byte [eax + 0x11], 0
je 0x5159f9
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.Socket_recv_aborted_by_application
mov ecx, esi
call eax
jmp 0x515a16
cmp byte [eax + 0x10], 0
jne 0x515a16
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.Socket_recv_failed.
mov ecx, esi
call eax
jmp 0x515a16
mov ecx, dword [ebp + 0x18]
mov byte [ecx + 0x10], 1
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], 0xffffffff
call fcn.0046e4c0
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18