Function at 0x10013c90
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
mov dword [ebp - 0x48], ecx
mov dword [ebp - 4], 0
push 0
push 0
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 4]
mov dword [eax + 4], ecx
cmp dword [ebp - 4], 0
jne 0x10013d16
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0xc], eax
mov edx, dword [ebp + 8]
mov dword [ebp - 0x34], edx
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
je 0x10013cec
push 1
mov ecx, dword [ebp - 0x30]
mov edx, dword [ecx]
mov ecx, dword [ebp - 0x30]
call dword [edx]
mov dword [ebp - 0x4c], eax
jmp 0x10013cf3
mov dword [ebp - 0x4c], 0
call fcn.10009e60
push eax
mov eax, dword [ebp - 0xc]
push eax
lea ecx, [ebp - 0x14]
call fcn.1000ee40
push str.thread.entry_event
lea ecx, [ebp - 0x14]
push ecx
call fcn.10009a80
add esp, 8
push 0
push 0
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov edx, dword [ebp - 0x48]
mov dword [edx + 8], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x48]
mov edx, dword [ecx + 8]
mov dword [eax + 8], edx
mov eax, dword [ebp - 0x48]
cmp dword [eax + 8], 0
jne 0x10013d95
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x3c], ecx
mov edx, dword [ebp - 0x3c]
mov dword [ebp - 0x38], edx
cmp dword [ebp - 0x38], 0
je 0x10013d6b
push 1
mov eax, dword [ebp - 0x38]
mov edx, dword [eax]
mov ecx, dword [ebp - 0x38]
call dword [edx]
mov dword [ebp - 0x50], eax
jmp 0x10013d72
mov dword [ebp - 0x50], 0
call fcn.10009e60
push eax
mov eax, dword [ebp - 0x18]
push eax
lea ecx, [ebp - 0x20]
call fcn.1000ee40
push str.thread.exit_event
lea ecx, [ebp - 0x20]
push ecx
call fcn.10009a80
add esp, 8
mov dword [ebp - 8], 0
lea edx, [ebp - 8]
push edx
push 0
mov eax, dword [ebp + 8]
push eax
push 0x10013e70
mov ecx, dword [ebp + 0xc]
push ecx
push 0
call dword [sym.imp.MSVCR71.dll__beginthreadex]
add esp, 0x18
mov edx, dword [ebp - 0x48]
mov dword [edx + 4], eax
mov eax, dword [ebp - 0x48]
cmp dword [eax + 4], 0
jne 0x10013e45
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x44], ecx
mov edx, dword [ebp - 0x44]
mov dword [ebp - 0x40], edx
cmp dword [ebp - 0x40], 0
je 0x10013df5
push 1
mov eax, dword [ebp - 0x40]
mov edx, dword [eax]
mov ecx, dword [ebp - 0x40]
call dword [edx]
mov dword [ebp - 0x54], eax
jmp 0x10013dfc
mov dword [ebp - 0x54], 0
cmp dword [ebp - 4], 0
je 0x10013e0c
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x48]
cmp dword [ecx + 8], 0
je 0x10013e22
mov edx, dword [ebp - 0x48]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.10009e60
push eax
mov ecx, dword [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x2c]
call fcn.1000ee40
push str.thread
lea edx, [ebp - 0x2c]
push edx
call fcn.10009a80
add esp, 8
cmp dword [ebp - 4], 0
je 0x10013e61
push 0xffffffffffffffff
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esp, ebp
pop ebp
ret 8