Function at 0x404370
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
sub esp, 0x438
lea ecx, [esp + 0xc]
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x450]
xor ebx, ebx
xor esi, esi
mov ax, word [edi + 0x1c6]
lea ebp, [edi + 0x146]
push eax
push ebp
push ecx
call fcn.00409020
add esp, 0xc
test eax, eax
jne 0x4045c0
movsx edx, word [edi + 0x1c6]
mov eax, dword [esp + 0x1e]
push edx
push ebp
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
mov ecx, dword [esp + 0x28]
and eax, 0xffff
push eax
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push 0x442638
call fcn.004081f0
mov eax, dword [esp + 0x470]
add esp, 0x14
cmp eax, ebx
je 0x40442f
mov eax, dword [esp + 0x20]
mov esi, dword [esp + 0x44c]
xor edx, edx
mov cx, word [esp + 0x1e]
mov dword [esp + 0x10], edx
push ebx
mov dword [esp + 0x18], edx
mov dword [esp + 0x18], eax
mov eax, dword [esi]
mov word [esp + 0x1c], dx
lea edx, [esp + 0x14]
push 0xa
push edx
mov byte [esp + 0x1c], 5
mov byte [esp + 0x1d], 1
mov byte [esp + 0x1e], bl
mov byte [esp + 0x1f], 1
mov word [esp + 0x24], cx
push eax
jmp 0x404486
mov ecx, dword [esp + 0x460]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
mov esi, dword [esp + 0x44c]
xor edx, edx
mov dword [esp + 0x10], edx
push ebx
mov ecx, dword [esi]
mov dword [esp + 0x18], edx
mov word [esp + 0x1c], dx
mov word [esp + 0x1c], ax
lea eax, [esp + 0x14]
push 0xa
push eax
mov byte [esp + 0x1c], 5
mov byte [esp + 0x1d], 3
mov byte [esp + 0x1e], bl
mov byte [esp + 0x1f], 1
mov byte [esp + 0x20], bl
mov byte [esp + 0x21], bl
mov byte [esp + 0x22], bl
mov byte [esp + 0x23], bl
push ecx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, ebx
jle 0x4045b3
mov eax, dword [esi]
push ebx
lea edx, [esp + 0x4c]
push 0x400
push edx
push eax
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 9
jge 0x4044f6
push 0x4a1
push str.D:QLiveQ_3_27QLiveQ_3_32QLiveQSocket5Proxy.h
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, dword [esp + 0x2a]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_ntohs]
mov edx, dword [esp + 0x30]
and eax, 0xffff
push eax
push edx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push 0x4425f0
call fcn.004081f0
add esp, 0x1c
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x438
ret
lea eax, [esp + 0x48]
test eax, eax
je 0x404587
cmp byte [esp + 0x48], 5
jne 0x404587
cmp byte [esp + 0x49], bl
jne 0x404587
cmp byte [esp + 0x4a], bl
jne 0x404587
cmp byte [esp + 0x4b], 1
jne 0x404587
movsx ecx, word [edi + 0x1c6]
mov eax, dword [esp + 0x50]
mov esi, dword [esp + 0x4c]
push ecx
push ebp
push eax
mov word [esp + 0x44], ax
call dword [sym.imp.WS2_32.dll_ntohs]
and eax, 0xffff
push eax
push esi
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push 0x4425cc
call fcn.004081f0
mov ecx, dword [esp + 0x470]
add esp, 0x14
cmp ecx, ebx
mov eax, 1
jne 0x4045c2
mov edx, dword [esp + 0x458]
mov cx, word [esp + 0x38]
pop edi
mov word [edx], cx
mov edx, dword [esp + 0x450]
mov dword [edx], esi
pop esi
pop ebp
pop ebx
add esp, 0x438
ret
movsx eax, word [edi + 0x1c6]
movsx ecx, word [edi + 0x84]
push 0x4b7
push str.D:QLiveQ_3_27QLiveQ_3_32QLiveQSocket5Proxy.h
push eax
push ebp
add edi, 4
push ecx
push edi
push 0x4425a0
call fcn.004081f0
add esp, 0x1c
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x438
ret
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x438
ret