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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x748478
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
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
mov esi, dword [ebp + 0x14]
mov eax, dword [esi + 4]
mov ecx, esi
mov dword [ebp - 0x1c], eax
call fcn.004a71c0
cmp byte [edi + 0x12], 0
je 0x515cc6
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov eax, dword [str.Another_thread_is_closing_this_socket.]
mov edx, dword [edx + 0x14]
push eax
call edx
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 0x10
mov ebx, dword [ebp + 0x10]
mov byte [ebp - 0xe], 0
mov byte [ebp - 0xf], 0
mov dword [ebp - 0x18], 0
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
je 0x515ce9
push ebx
call fcn.00487de0
test al, al
jne 0x515cb0
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x14], eax
mov byte [ebp + 0x10], 0
cmp eax, 0xabcd0123
jne 0x515d05
mov byte [ebp + 0x10], 1
mov dword [ebp - 0x14], 1
mov ecx, esi
call fcn.004a71c0
cmp dword [edi + 0xb4], 0xffffffff
je 0x515e9b
cmp byte [edi + 0x11], 0
lea eax, [edi + 0x11]
jne 0x515ebb
cmp byte [edi + 0x12], 0
jne 0x515ece
push eax
lea ecx, [ebp - 0x28]
call fcn.0046e4a0
cmp dword [ebp - 0x14], 0
mov dword [ebp - 4], 0
jne 0x515d4d
mov dword [ebp - 0x14], 0xc042c00
mov eax, dword [esi + 4]
push ebx
push eax
lea ecx, [edi + 0x150]
push 0x1000
call fcn.00566620
test al, al
jne 0x515ee3
cmp byte [edi + 0x12], al
jne 0x515efa
or esi, 0xffffffff
cmp dword [edi + 0xb4], esi
je 0x515f0f
mov byte [ebp - 0xd], 1
mov edx, dword [edi + 0xb4]
push 0
push 1
lea ecx, [ebp - 0x20]
push ecx
push edx
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
test esi, esi
jg 0x515e02
je 0x515f25
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x515f5b
cmp byte [ebp - 0xd], 0
je 0x515fbd
cmp byte [ebp + 0x10], 0
jne 0x515fbd
mov ecx, dword [ebp + 0x14]
push ebx
call fcn.004a71f0
test al, al
jne 0x515fc4
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x14]
push ebx
push eax
push ecx
mov ecx, edi
call fcn.00513e90
test al, al
je 0x515f8e
mov byte [ebp - 0xd], 0
test esi, esi
js 0x515d86
jmp 0x515fc4
lea edx, [esi - 0x1000]
push edx
lea ecx, [edi + 0x150]
call fcn.00566820
cmp byte [edi + 0x278], 0
je 0x515e2e
mov eax, dword [ebp + 0x14]
mov ecx, dword [eax + 4]
push ebx
push ecx
push esi
lea ecx, [edi + 0x20]
call fcn.004a6c80
cmp byte [edi + 0x275], 0
je 0x515e4c
mov edx, dword [ebp + 0x14]
mov ecx, dword [edx + 4]
test ecx, ecx
je 0x515e4c
mov eax, esi
cdq
push ebx
push edx
push eax
call fcn.00488110
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], 0xffffffff
call fcn.0046e4c0
mov eax, dword [ebp - 0x20]
cmp al, 0xa
je 0x515e6b
cmp al, 0xd
je 0x515e80
inc dword [ebp - 0x18]
jmp 0x515e80
cmp dword [ebp - 0x18], 0
jne 0x515e79
mov byte [ebp - 0xe], 1
mov byte [ebp - 0xf], 1
mov dword [ebp - 0x18], 0
mov ecx, dword [ebp + 8]
push eax
call fcn.00410ec0
cmp byte [ebp - 0xe], 0
jne 0x515fd3
mov esi, dword [ebp + 0x14]
jmp 0x515cd8
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push str.This_socket_is_not_connected
mov ecx, ebx
call edx
mov byte [esi + 0x12], 1
mov word [edi + 0xb0], 0
jmp 0x515fd3
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push str.Another_thread_is_already_receiving_on_this_socket.
mov ecx, ebx
call edx
jmp 0x515fd3
mov ecx, dword [str.Another_thread_is_closing_this_socket.]
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push ecx
mov ecx, ebx
call edx
jmp 0x515fd3
mov byte [esi + 0x11], 1
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push str.Aborted_by_application_while_download_throttling__2_
mov ecx, ebx
call edx
jmp 0x515fc4
mov ecx, dword [str.Another_thread_is_closing_this_socket.]
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push ecx
mov ecx, ebx
call edx
jmp 0x515fc4
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push str.The_socket_is_already_closed.__Cannot_recv.
mov ecx, ebx
call edx
mov dword [ebp - 4], esi
jmp 0x515fcb
cmp byte [ebx + 0xad], 0
je 0x515f4a
push 1
push str.maxToReceive
mov ecx, ebx
call fcn.00474a80
mov eax, dword [ebx]
mov edx, dword [eax + 0x14]
push str.Connection_closed_by_peer.
mov ecx, ebx
call edx
push ebx
mov ecx, edi
call fcn.005151f0
mov eax, dword [ebp + 0x14]
mov byte [eax + 0x13], 1
jmp 0x515fc4
mov ecx, ebx
call fcn.00474d10
push 1
push str.maxToReceive
mov ecx, ebx
call fcn.00474a80
mov edx, dword [ebx]
mov eax, dword [edx + 0x14]
push str.Failed_to_receive_data_on_the_TCP_socket
mov ecx, ebx
call eax
mov ecx, dword [ebp + 0x14]
mov byte [ecx + 0x12], 1
mov byte [edi + 0xb0], 0
jmp 0x515fc4
mov eax, dword [ebp + 0x14]
cmp byte [eax + 0x11], 0
je 0x515fa7
mov edx, dword [ebx]
mov eax, dword [edx + 0x14]
push str.Socket_recv_aborted_by_application
mov ecx, ebx
call eax
jmp 0x515fc4
cmp byte [eax + 0x10], 0
jne 0x515fc4
mov edx, dword [ebx]
mov eax, dword [edx + 0x14]
push str.Socket_recv_failed.
mov ecx, ebx
call eax
jmp 0x515fc4
mov ecx, dword [ebp + 0x14]
mov byte [ecx + 0x10], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0046e4c0
mov al, byte [ebp - 0xf]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10