Function at 0x4c3010
Capabilities:
Terminate process

Disassembly:
sub esp, 8
push ebx
push esi
push edi
mov ebx, edx
mov edi, ecx
mov eax, dword [edi + ebx*4 + 0x170]
test eax, eax
jne 0x4c306f
push 0x140
call fcn.0058db11
mov esi, eax
add esp, 4
test esi, esi
je 0x4c329c
push 0x140
push 0
push esi
call fcn.00587250
mov dword [esi + 0x118], 0x24
lea eax, [esi + 0x11c]
mov dword [edi + ebx*4 + 0x170], esi
mov dword [esi + 0x40], eax
mov dword [eax + 0x1c], 4
jmp 0x4c30fe
push dword [eax + 0x74]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [edi + ebx*4 + 0x170]
call fcn.004bbb80
push 0x118
push 0
push dword [edi + ebx*4 + 0x170]
call fcn.00587250
mov edx, dword [edi + ebx*4 + 0x170]
add esp, 0xc
mov ecx, edx
xorps xmm0, xmm0
neg ecx
lea eax, [edx + 0x11c]
sbb ecx, ecx
and ecx, eax
mov dword [edx + 0x40], ecx
mov eax, dword [edi + ebx*4 + 0x170]
mov eax, dword [eax + 0x40]
movups xmmword [eax], xmm0
movq qword [eax + 0x10], xmm0
mov dword [eax + 0x18], 0
mov eax, dword [edi + ebx*4 + 0x170]
mov ecx, dword [eax + 0x40]
mov edx, ecx
neg edx
sbb edx, edx
lea eax, [ecx + 0x20]
and edx, eax
jne 0x4c30e9
xor eax, eax
jmp 0x4c30ec
mov eax, dword [edx - 4]
push eax
lea eax, [ecx + 0x20]
neg ecx
push 0
sbb ecx, ecx
and ecx, eax
push ecx
call fcn.00587250
mov edx, dword [esp + 0x24]
add esp, 0xc
mov eax, dword [edi + edx*4 + 0x148]
push 0
push 0x40
push 1
mov dword [eax + 0x74], ebx
lea eax, [ebx + 1]
mov dword [edi + 0x198], eax
mov eax, dword [edi + ebx*4 + 0x170]
push 0
mov dword [eax + 0x28], 0x50
mov ecx, dword [edi + ebx*4 + 0x170]
mov eax, dword [edi + 0xc]
mov dword [ecx + 0xc], eax
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x18], 0x4c2fb0
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x1c], fcn.004c0240
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x20], 0x4bc210
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x3c], edx
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x70], 4
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x38], ebx
call dword [sym.imp.KERNEL32.dll_CreateSemaphoreA]
mov ecx, dword [edi + ebx*4 + 0x170]
mov edx, 0x1c
mov dword [ecx + 0x74], eax
mov ecx, 0x10
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x2c], edi
mov eax, dword [esp + 0x1c]
cmp word [eax], 0x17
cmove ecx, edx
push ecx
mov ecx, dword [edi + ebx*4 + 0x170]
push eax
mov ecx, dword [ecx + 0x40]
call fcn.00401000
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x54], 0x15e0
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0x58], 0x15e0
push dword [edi + 0x140]
call fcn.00562d00
mov ecx, dword [edi + ebx*4 + 0x170]
add esp, 0xc
mov dword [ecx + 0x30], eax
mov eax, dword [edi + ebx*4 + 0x170]
push edi
push dword [0x627760]
push dword [eax + 0x30]
call fcn.00563560
add esp, 0xc
push 0x1000
call fcn.0058db11
mov ecx, dword [edi + ebx*4 + 0x170]
add esp, 4
mov dword [ecx + 0xe4], eax
test eax, eax
je 0x4c32dd
mov eax, dword [edi + ebx*4 + 0x170]
mov dword [eax + 0xec], 0x1000
mov ecx, dword [edi + ebx*4 + 0x170]
call fcn.004bbc30
lea eax, [esp + 0x10]
mov edx, 4
push eax
lea eax, [esp + 0x10]
push eax
lea ecx, [edx + 0x14]
call fcn.004aeee0
mov esi, dword [esp + 0x14]
add esp, 8
mov eax, dword [esp + 0x10]
push 0
push 0x40
push 1
push 0
mov dword [esi + 0x14], eax
call dword [sym.imp.KERNEL32.dll_CreateSemaphoreA]
mov dword [esi], eax
mov eax, dword [edi + ebx*4 + 0x170]
pop edi
mov dword [eax + 0xd8], esi
pop esi
pop ebx
add esp, 8
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0xfe
push 0x4c4
mov edx, 0x624148
xor ecx, ecx
call fcn.004b4f80
add esp, 0xc
push 0x4c4
push 0x624164
push 0x624180
call fcn.004010e0
add esp, 0xc
push 0xfe
call fcn.005885bd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0xfe
push 0x1611
mov edx, 0x627364
xor ecx, ecx
call fcn.004b4f80
add esp, 0xc
push 0x1611
push 0x627380
push 0x62739c
call fcn.004010e0
add esp, 0xc
push 0xfe
call fcn.005885bd
int3