Function at 0x100c57b
Capabilities:
Create thread

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
lea eax, [ebp - 0x30]
xor ebx, ebx
push eax
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x10], ebx
mov byte [ebp - 1], 1
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push ebx
push ebx
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
cmp eax, ebx
mov dword [ebp - 0x14], eax
je 0x100c5c6
push 0x12
push 1
call fcn.0101231f
cmp eax, 0xffffffff
mov dword [ebp - 0xc], eax
jne 0x100c5d7
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
xor al, al
jmp 0x100c770
push esi
push edi
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea eax, [ebp - 8]
push eax
push ebx
push dword [ebp - 0xc]
call fcn.01013b09
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x100c650
push 0x18
call int.0102ec4e
mov esi, eax
cmp esi, ebx
pop ecx
je 0x100c65b
mov eax, dword [ebp - 0x18]
mov dword [esi], eax
mov eax, dword [ebp - 8]
mov dword [esi + 4], eax
push ebx
push ebx
lea eax, [ebp - 0x30]
mov dword [esi + 8], eax
push esi
lea eax, [ebp - 0x10]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x14]
push 0x100b89c
mov dword [esi + 0x10], eax
push ebx
lea eax, [ebp - 1]
push ebx
mov dword [esi + 0x14], eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, ebx
je 0x100c660
inc dword [ebp - 0x10]
push eax
call edi
lea eax, [ebp - 8]
push eax
push ebx
push dword [ebp - 0xc]
call fcn.01013b09
shr eax, 0xf
not eax
test al, 1
jne 0x100c5f8
jmp 0x100c66a
mov byte [ebp - 1], bl
jmp 0x100c66a
push esi
mov byte [ebp - 1], bl
call fcn.0102ec42
pop ecx
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push dword [ebp - 0xc]
call fcn.010124dd
cmp dword [ebp - 0x10], ebx
je 0x100c68c
push 0xffffffffffffffff
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x14]
call edi
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
cmp byte [ebp - 1], bl
je 0x100c6b1
push 0x12
push 2
call fcn.0101231f
cmp eax, 0xffffffff
mov dword [ebp - 0xc], eax
jne 0x100c6b8
xor al, al
jmp 0x100c76e
lea ecx, [ebp - 8]
push ecx
push 1
push eax
jmp 0x100c734
push 0xd0
call int.0102ec4e
cmp eax, ebx
pop ecx
je 0x100c6de
push dword [ebp - 8]
mov ecx, eax
call fcn.0100684a
mov esi, eax
jmp 0x100c6e0
xor esi, esi
cmp esi, ebx
push dword [ebp - 8]
je 0x100c748
mov ecx, esi
call fcn.01007d95
test al, al
je 0x100c74f
push 0x80000000
mov ecx, esi
call fcn.01006a65
push dword [ebp - 8]
mov edi, eax
call fcn.0101202b
push edi
mov ecx, esi
call fcn.0100ad90
cmp edi, ebx
je 0x100c71f
cmp edi, 0xffffffff
je 0x100c71f
push edi
call fcn.0101f4b2
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 4]
push esi
call fcn.01020e65
lea eax, [ebp - 8]
push eax
push 1
push dword [ebp - 0xc]
call fcn.01013b09
shr eax, 0xf
not eax
test al, 1
jne 0x100c6c1
jmp 0x100c763
call fcn.0101202b
jmp 0x100c760
push dword [ebp - 8]
call fcn.0101202b
push 1
mov ecx, esi
call fcn.01009ebd
mov byte [ebp - 1], bl
push dword [ebp - 0xc]
call fcn.010124dd
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
leave
ret