Function at 0x403b40
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x450110
mov eax, dword fs:[0]
push eax
sub esp, 0x60
push esi
mov eax, dword [0x46c098]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [esi + 0x108], eax
test eax, eax
jne 0x403c4c
call fcn.004214d0
lea eax, [ebp - 0x54]
push eax
call fcn.00422de0
add esp, 4
mov edx, eax
mov dword [ebp - 4], 0
cmp dword [edx + 0x14], 0x10
jb 0x403ba6
mov edx, dword [edx]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
cmp byte [edx], 0
jne 0x403bc1
xor ecx, ecx
jmp 0x403bcf
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403bc6
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x24]
call fcn.00402dd0
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x24]
push str.CMonitorThread::StartThread_CreateEvent_Failed_ErrorCode___d
push eax
call fcn.00421490
add esp, 4
push eax
call fcn.004212a0
mov eax, dword [ebp - 0x10]
add esp, 0xc
cmp eax, 0x10
jb 0x403c13
inc eax
lea ecx, [ebp - 0x24]
push eax
push dword [ebp - 0x24]
call fcn.00403540
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
cmp eax, 0x10
jb 0x403c3a
inc eax
lea ecx, [ebp - 0x54]
push eax
push dword [ebp - 0x54]
call fcn.00403540
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [esi + 0x10c], eax
test eax, eax
jne 0x403d08
call fcn.004214d0
lea eax, [ebp - 0x54]
push eax
call fcn.00422de0
add esp, 4
mov dword [ebp - 4], 2
cmp dword [eax + 0x14], 0x10
jb 0x403c88
mov eax, dword [eax]
push eax
lea ecx, [ebp - 0x24]
call fcn.00402ed0
mov byte [ebp - 4], 3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x24]
push str.CMonitorThread::StartThread_CreateEvent_Failed_ErrorCode___d
push eax
call fcn.00421490
add esp, 4
push eax
call fcn.004212a0
mov eax, dword [ebp - 0x10]
add esp, 0xc
cmp eax, 0x10
jb 0x403ccb
inc eax
lea ecx, [ebp - 0x24]
push eax
push dword [ebp - 0x24]
call fcn.00403540
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
cmp eax, 0x10
jb 0x403c3a
inc eax
lea ecx, [ebp - 0x54]
push eax
push dword [ebp - 0x54]
call fcn.00403540
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
lea ecx, [esi + 4]
mov edx, 0x3f
mov eax, dword [esi + 0x10c]
lea ecx, [ecx + 4]
mov dword [ecx - 4], eax
sub edx, 1
jne 0x403d10
lea eax, [esi + 0x100]
push eax
push edx
push esi
push 0x4037d0
push edx
push edx
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [esi + 0x104], eax
test eax, eax
jne 0x403e11
call fcn.004214d0
lea eax, [ebp - 0x54]
push eax
call fcn.00422de0
add esp, 4
mov edx, eax
mov dword [ebp - 4], 4
cmp dword [edx + 0x14], 0x10
jb 0x403d67
mov edx, dword [edx]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
cmp byte [edx], 0
jne 0x403d82
xor ecx, ecx
jmp 0x403d90
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403d87
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x24]
call fcn.00402dd0
mov byte [ebp - 4], 5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x24]
push str.CMonitorThread::StartThread_CreateThread_Failed_ErrorCode___d
push eax
call fcn.00421490
add esp, 4
push eax
call fcn.004212a0
mov eax, dword [ebp - 0x10]
add esp, 0xc
cmp eax, 0x10
jb 0x403dd4
inc eax
lea ecx, [ebp - 0x24]
push eax
push dword [ebp - 0x24]
call fcn.00403540
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
cmp eax, 0x10
jb 0x403c3a
inc eax
lea ecx, [ebp - 0x54]
push eax
push dword [ebp - 0x54]
call fcn.00403540
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
push 0x7d0
push dword [esi + 0x108]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x403efa
call fcn.004214d0
lea eax, [ebp - 0x6c]
push eax
call fcn.00422de0
add esp, 4
mov edx, eax
mov dword [ebp - 4], 6
cmp dword [edx + 0x14], 0x10
jb 0x403e4c
mov edx, dword [edx]
mov dword [ebp - 0x28], 0xf
mov dword [ebp - 0x2c], 0
mov byte [ebp - 0x3c], 0
cmp byte [edx], 0
jne 0x403e67
xor ecx, ecx
jmp 0x403e79
mov ecx, edx
lea esi, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403e70
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x3c]
call fcn.00402dd0
mov byte [ebp - 4], 7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x3c]
push str.CMonitorThread::StartThread_WaitForSingleObject_NOT_WAIT_OBJECT_0__ErrorCode___d
push eax
call fcn.00421490
add esp, 4
push eax
call fcn.00421a60
mov eax, dword [ebp - 0x28]
add esp, 0xc
cmp eax, 0x10
jb 0x403ebd
inc eax
lea ecx, [ebp - 0x3c]
push eax
push dword [ebp - 0x3c]
call fcn.00403540
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x28], 0xf
mov dword [ebp - 0x2c], 0
mov byte [ebp - 0x3c], 0
cmp eax, 0x10
jb 0x403c3a
inc eax
lea ecx, [ebp - 0x6c]
push eax
push dword [ebp - 0x6c]
call fcn.00403540
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret