Function at 0x4bc374
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffcc
mov eax, 0x4ca6f0
call fcn.004aff88
mov edx, dword [ebp + 8]
cmp byte [edx + 0x70], 0
je 0x4bc39e
mov ecx, dword [ebp - 0x2c]
mov dword fs:[0], ecx
mov eax, ecx
jmp 0x4bc5cf
mov edx, dword [ebp + 8]
mov al, byte [edx + 0x59]
push eax
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_Create_q17TcmSocketProtocol
add esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 0x88], eax
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0x88], 0xffffffff
jne 0x4bc3d3
mov eax, dword [ebp - 0x2c]
mov dword fs:[0], eax
jmp 0x4bc5cf
mov edx, dword [ebp + 8]
cmp byte [edx + 0x58], 1
jne 0x4bc40b
mov dword [ebp - 0x30], 1
push str.ioctlsocket___set_block_mode_error
lea ecx, [ebp - 0x30]
push ecx
push 0x8004667e
mov eax, dword [ebp + 8]
push dword [eax + 0x88]
call sub.WSOCK32.DLL_ioctlsocket
push eax
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_ErrorCheck_qipc
add esp, 0xc
mov edx, dword [ebp + 8]
cmp byte [edx + 0x59], 2
jne 0x4bc436
mov dword [ebp - 0x34], 1
push 4
lea ecx, [ebp - 0x34]
push ecx
push 0x20
push 0xffff
mov eax, dword [ebp + 8]
push dword [eax + 0x88]
call sub.WSOCK32.DLL_setsockopt
mov word [ebp - 0x1c], 8
lea eax, [ebp - 4]
xor edx, edx
call fcn.004bb4a4
inc dword [ebp - 0x10]
lea edx, [ebp - 4]
mov eax, dword [ebp + 8]
add eax, 0x78
call fcn.004bb638
test al, al
jne 0x4bc46e
mov eax, dword [ebp + 8]
add eax, 0x78
call fcn.0040bb60
test al, al
jne 0x4bc46e
xor edx, edx
jmp 0x4bc473
mov edx, 1
push edx
dec dword [ebp - 0x10]
lea eax, [ebp - 4]
mov edx, 2
call fcn.004bb554
pop ecx
test cl, cl
je 0x4bc4c3
mov word [ebp - 0x1c], 0x14
push 0xffffffffffffffff
lea eax, [ebp - 8]
call fcn.00408e34
push eax
inc dword [ebp - 0x10]
call sym.Project1.exe__TcmSocket_HostIP_qul
add esp, 8
lea edx, [ebp - 8]
mov eax, dword [ebp + 8]
add eax, 0x78
call fcn.004bb584
dec dword [ebp - 0x10]
lea eax, [ebp - 8]
mov edx, 2
call fcn.004bb554
mov ecx, dword [ebp + 8]
push dword [ecx + 0x80]
mov eax, dword [ebp + 8]
add eax, 0x78
call fcn.0040abb0
push eax
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_Bind_qpcui
add esp, 0xc
mov edx, dword [ebp + 8]
mov byte [edx + 0x72], al
mov ecx, dword [ebp + 8]
cmp byte [ecx + 0x72], 0
je 0x4bc5a4
mov eax, dword [ebp + 8]
cmp byte [eax + 0x59], 4
jne 0x4bc517
push 5
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_Listen_qi
add esp, 8
mov edx, dword [ebp + 8]
mov byte [edx + 0x70], al
jmp 0x4bc5a4
mov ecx, dword [ebp + 8]
cmp byte [ecx + 0x59], 5
jne 0x4bc548
mov eax, dword [ebp + 8]
push dword [eax + 0x84]
mov eax, dword [ebp + 8]
add eax, 0x7c
call fcn.0040abb0
push eax
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_Connect_qpcui
add esp, 0xc
mov edx, dword [ebp + 8]
mov byte [edx + 0x70], al
jmp 0x4bc5a4
mov ecx, dword [ebp + 8]
cmp byte [ecx + 0x59], 2
jne 0x4bc59d
mov eax, dword [ebp + 8]
add eax, 0x7c
call fcn.0040bb60
test al, al
jne 0x4bc594
mov edx, dword [ebp + 8]
cmp dword [edx + 0x84], 0
jle 0x4bc594
mov ecx, dword [ebp + 8]
push dword [ecx + 0x84]
mov eax, dword [ebp + 8]
add eax, 0x7c
call fcn.0040abb0
push eax
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_Connect_qpcui
add esp, 0xc
mov edx, dword [ebp + 8]
mov byte [edx + 0x70], al
jmp 0x4bc5a4
mov ecx, dword [ebp + 8]
mov byte [ecx + 0x70], 1
jmp 0x4bc5a4
mov eax, dword [ebp + 8]
mov byte [eax + 0x70], 1
mov edx, dword [ebp + 8]
cmp byte [edx + 0x70], 0
je 0x4bc5ba
push 1
push dword [ebp + 8]
call sym.Project1.exe__TcmSocket_DeclareConnect_qo
add esp, 8
mov ecx, dword [ebp + 8]
xor eax, eax
mov dword [ecx + 0x8c], eax
mov edx, dword [ebp - 0x2c]
mov dword fs:[0], edx
mov esp, ebp
pop ebp
ret