Function at 0x401310
Capabilities:
Terminate process

Disassembly:
sub esp, 0x1a0
push edi
xor edi, edi
push edi
call dword [sym.imp.ole32.dll_CoInitialize]
mov eax, dword [0x40caa8]
push eax
push 0x40b0b0
call fcn.004012e0
add esp, 8
test eax, eax
jne 0x40133e
push edi
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push edi
push edi
push edi
push edi
call dword [sym.imp.USER32.dll_DefWindowProcA]
lea ecx, [esp + 0x3c]
push ecx
mov dword [esp + 0x40], 8
mov dword [esp + 0x44], 0x404
call dword [sym.imp.COMCTL32.dll_InitCommonControlsEx]
push edi
mov ecx, 0x40ca18
mov edx, dword [esp + 0x1ac]
push edx
push edi
call fcn.004019a0
test eax, eax
jl 0x4013b5
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push 0xc
mov dword [0x40ca9c], eax
mov dword [0x40caa0], edi
call fcn.00403eac
add esp, 4
cmp eax, edi
je 0x4013a4
mov dword [eax], edi
mov dword [eax + 4], edi
mov dword [eax + 8], edi
jmp 0x4013a6
xor eax, eax
cmp eax, edi
mov dword [0x40caa0], eax
je 0x4013b5
mov dword [0x40caa4], edi
lea ecx, [esp + 0x14]
mov dword [esp + 8], edi
mov dword [esp + 0xc], edi
mov dword [esp + 0x10], edi
call fcn.00401810
lea eax, [esp + 4]
mov dword [esp + 4], 0x40920c
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [0x40caa0]
push eax
call fcn.00401820
lea ecx, [esp + 0x44]
call fcn.00401800
lea ecx, [esp + 0x60]
call fcn.00401a70
lea ecx, [esp + 0x44]
lea edx, [esp + 0x4c]
push ecx
push edx
push 0x40ca18
mov dword [esp + 0x8c], edi
mov dword [esp + 0x90], edi
mov dword [esp + 0x50], 0x409200
call fcn.00401b10
mov eax, dword [0x40ca20]
push edi
push 0x401da0
push edi
push 0x81
push eax
call dword [sym.imp.USER32.dll_CreateDialogParamA]
test eax, eax
jne 0x401472
lea ecx, [esp + 0x44]
lea eax, [esp + 0x60]
neg ecx
sbb ecx, ecx
and ecx, eax
call fcn.00401d30
lea ecx, [esp + 0x14]
call fcn.00401af0
lea ecx, [esp + 8]
call fcn.00401af0
xor eax, eax
pop edi
add esp, 0x1a0
ret 0x10
mov ecx, dword [esp + 0x48]
push ebx
push ebp
push esi
push edi
push ecx
call dword [sym.imp.USER32.dll_ShowWindow]
mov ebp, dword [sym.imp.USER32.dll_PeekMessageA]
mov esi, 1
xor ebx, ebx
push edi
push edi
push edi
lea edx, [esp + 0x38]
push edi
push edx
call ebp
test eax, eax
jne 0x4014c5
cmp esi, edi
je 0x4014c5
mov eax, ebx
lea ecx, [esp + 0x10]
push eax
mov eax, dword [esp + 0x14]
inc ebx
call dword [eax + 4]
test eax, eax
jne 0x4014b6
xor esi, esi
push edi
push edi
push edi
lea ecx, [esp + 0x38]
push edi
push ecx
call ebp
test eax, eax
je 0x40149d
push edi
push edi
lea edx, [esp + 0x34]
push edi
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
cmp eax, 0xffffffff
je 0x40148e
cmp eax, edi
je 0x401526
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x14]
call dword [edx]
test eax, eax
jne 0x401505
lea eax, [esp + 0x2c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea ecx, [esp + 0x2c]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
lea edx, [esp + 0x2c]
push edx
call fcn.00401b50
add esp, 4
test eax, eax
je 0x40148e
mov esi, 1
xor ebx, ebx
jmp 0x40148e
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [0x40caa0]
push eax
call fcn.004018a0
lea ecx, [esp + 0x50]
lea eax, [esp + 0x6c]
neg ecx
sbb ecx, ecx
and ecx, eax
call fcn.00401d30
lea ecx, [esp + 0x20]
call fcn.00401af0
lea ecx, [esp + 0x14]
call fcn.00401af0
mov ecx, 0x40ca18
call fcn.00401c00
call dword [sym.imp.ole32.dll_CoUninitialize]
pop esi
pop ebp
pop ebx
xor eax, eax
pop edi
add esp, 0x1a0
ret 0x10