Function at 0x40e230
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
push 0xffffffffffffffff
push 0x4b06d4
mov eax, dword fs:[0]
push eax
sub esp, 0xe8
push ebx
push esi
push edi
mov eax, dword [0x4ca1d0]
xor eax, esp
push eax
lea eax, [esp + 0xf8]
mov dword fs:[0], eax
mov esi, ecx
cmp dword [ebp + 8], 0xffffffff
je 0x40e861
lea eax, [esi + 0x318]
push eax
mov dword [esp + 0x60], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [esp + 0x60], 1
mov eax, dword [0x4d3dcc]
mov edx, dword [eax + 0xc]
mov ecx, 0x4d3dcc
mov dword [esp + 0x100], 0
call edx
add eax, 0x10
mov dword [esp + 0x28], eax
mov eax, dword [0x4d3dcc]
mov edx, dword [eax + 0xc]
mov ecx, 0x4d3dcc
mov byte [esp + 0x100], 1
call edx
add eax, 0x10
mov dword [esp + 0x3c], eax
lea eax, [ebp + 8]
push eax
lea ecx, [esp + 0x34]
lea edi, [esi + 0x2bc]
push ecx
mov ecx, edi
mov byte [esp + 0x108], 2
call fcn.00408330
mov ebx, dword [edi + 0x18]
mov eax, dword [edi]
mov edi, dword [esp + 0x30]
test edi, edi
je 0x40e2f2
cmp edi, eax
je 0x40e2f7
call fcn.00494198
cmp dword [esp + 0x34], ebx
je 0x40e466
test edi, edi
jne 0x40e45f
call fcn.00494198
mov edx, dword [esp + 0x34]
cmp edx, dword [edi + 0x18]
jne 0x40e31c
call fcn.00494198
mov ecx, dword [esp + 0x34]
mov ecx, dword [ecx + 0x10]
lea eax, [esp + 0x2c]
push eax
call fcn.00413d70
mov edx, dword [eax]
cmp dword [edx - 0xc], 0
mov eax, dword [esp + 0x2c]
sete bl
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e356
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
je 0x40e43e
mov ebx, dword [ebp + 8]
lea ecx, [esp + 0x2c]
push ebx
push ecx
call fcn.0040dc00
add esp, 8
push eax
lea ecx, [esp + 0x2c]
mov byte [esp + 0x104], 3
call fcn.0040a460
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 2
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40e3a9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [esp + 0x28]
push edi
lea ecx, [esp + 0x34]
call fcn.00407800
mov ecx, dword [eax + 4]
call fcn.00416bb0
lea ecx, [esp + 0x2c]
push edi
push ecx
call fcn.0040ca50
add esp, 8
mov eax, dword [eax]
push eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x104], 4
call fcn.00407800
mov ecx, dword [eax + 4]
call fcn.00416bf0
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 2
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40e411
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [esp + 0x28]
call fcn.004081d0
lea ecx, [esp + 0x28]
push ecx
lea ecx, [esi + 0x2dc]
call fcn.0040d650
push ebx
lea ecx, [esp + 0x34]
mov dword [eax], ebx
call fcn.00407800
mov ecx, dword [eax + 4]
call fcn.00417360
mov eax, dword [esp + 0x3c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 1
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x40e822
mov edi, dword [edi]
jmp 0x40e30e
mov edx, dword [ebp + 8]
push edx
lea eax, [esp + 0x30]
push eax
call fcn.0040dc00
add esp, 8
push eax
lea ecx, [esp + 0x2c]
mov byte [esp + 0x104], 5
call fcn.0040a460
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e4b1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x28]
push ecx
lea edx, [esp + 0x30]
push edx
call fcn.0040ca50
add esp, 8
push eax
lea ecx, [esp + 0x40]
mov byte [esp + 0x104], 6
call fcn.0040a460
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e4fd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0x178
call fcn.004941c3
add esp, 4
mov dword [esp + 0x30], eax
mov byte [esp + 0x100], 7
test eax, eax
je 0x40e525
mov ecx, eax
call fcn.004190f0
mov edi, eax
jmp 0x40e527
xor edi, edi
push 8
mov byte [esp + 0x104], 2
call fcn.004941c3
add esp, 4
mov dword [esp + 0x30], eax
mov byte [esp + 0x100], 8
test eax, eax
je 0x40e554
mov ecx, eax
call fcn.00413930
mov ebx, eax
jmp 0x40e556
xor ebx, ebx
mov ecx, dword [ebp + 8]
push ecx
lea edx, [esp + 0x3c]
push edx
mov ecx, esi
mov byte [esp + 0x108], 2
mov dword [esp + 0x38], ebx
call fcn.0040b700
mov eax, dword [esp + 0x38]
push eax
mov byte [esp + 0x104], 9
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40e59e
mov ecx, dword [esp + 0x38]
push ecx
mov ecx, edi
call fcn.00419790
mov edx, dword [esp + 0x38]
push 0
push edx
jmp 0x40e5a5
mov eax, dword [esp + 0x38]
push 1
push eax
mov ecx, ebx
call fcn.00416d80
push ebx
mov ecx, edi
call fcn.00412990
mov ecx, dword [esp + 0x28]
push ecx
mov ecx, edi
call fcn.00416bb0
mov edx, dword [esp + 0x3c]
push edx
mov ecx, edi
call fcn.00416bf0
mov eax, dword [ebp + 8]
push eax
mov ecx, edi
call fcn.00417360
test esi, esi
je 0x40e5e3
lea eax, [esi + 0x270]
jmp 0x40e5e5
xor eax, eax
push edi
push eax
mov ecx, edi
call fcn.004129b0
lea ecx, [esp + 0x40]
push ecx
call fcn.00407b40
cmp dword [esp + 0x48], 0
jne 0x40e629
fld qword [esp + 0x40]
lea edx, [esp + 0xa4]
push edx
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e629
movzx eax, word [esp + 0xb0]
mov dword [esp + 0x58], eax
jmp 0x40e631
mov dword [esp + 0x58], 0xffffffff
cmp dword [esp + 0x48], 0
jne 0x40e662
fld qword [esp + 0x40]
lea ecx, [esp + 0x84]
push ecx
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e662
movzx edx, word [esp + 0x8e]
mov dword [esp + 0x50], edx
jmp 0x40e66a
mov dword [esp + 0x50], 0xffffffff
cmp dword [esp + 0x48], 0
jne 0x40e695
fld qword [esp + 0x40]
lea eax, [esp + 0x64]
push eax
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e695
movzx ecx, word [esp + 0x6c]
mov dword [esp + 0x54], ecx
jmp 0x40e69d
mov dword [esp + 0x54], 0xffffffff
cmp dword [esp + 0x48], 0
jne 0x40e6c8
fld qword [esp + 0x40]
lea edx, [esp + 0x74]
push edx
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e6c8
movzx eax, word [esp + 0x7a]
mov dword [esp + 0x4c], eax
jmp 0x40e6d0
mov dword [esp + 0x4c], 0xffffffff
cmp dword [esp + 0x48], 0
jne 0x40e701
fld qword [esp + 0x40]
lea ecx, [esp + 0x94]
push ecx
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e701
movzx edx, word [esp + 0x96]
mov dword [esp + 0x2c], edx
jmp 0x40e709
mov dword [esp + 0x2c], 0xffffffff
cmp dword [esp + 0x48], 0
jne 0x40e736
fld qword [esp + 0x40]
lea eax, [esp + 0xb4]
push eax
sub esp, 8
fstp qword [esp]
call dword [sym.imp.OLEAUT32.dll_UnRegisterTypeLib]
test eax, eax
je 0x40e736
movzx eax, word [esp + 0xb4]
jmp 0x40e739
or eax, 0xffffffff
mov edx, dword [esp + 0x3c]
push edx
mov edx, dword [esp + 0x2c]
mov ecx, dword [ebx]
push edx
mov edx, dword [esp + 0x60]
push edx
mov edx, dword [esp + 0x5c]
push edx
mov edx, dword [esp + 0x64]
push edx
mov edx, dword [esp + 0x60]
push edx
mov edx, dword [esp + 0x44]
push edx
push eax
mov eax, dword [ecx + 4]
push str.Begin_Log___d__d__d__d:_d:_d___s__s
push ebx
call eax
add esp, 0x28
cmp dword [esi + 0x2d8], 0
jne 0x40e77f
push 1
mov ecx, edi
call fcn.00413090
lea ecx, [ebp + 8]
push ecx
lea ecx, [esi + 0x2bc]
call fcn.0040d750
lea ecx, [esp + 0x28]
mov dword [eax], edi
call fcn.004081d0
lea edx, [esp + 0x28]
push edx
lea ecx, [esi + 0x2dc]
call fcn.0040d650
mov ecx, dword [ebp + 8]
mov dword [eax], ecx
mov edi, dword [esi + 0x310]
mov eax, dword [edi + 4]
add esi, 0x2fc
lea edx, [esp + 0x30]
push edx
push eax
push edi
mov ecx, esi
call fcn.004079c0
push 1
mov ecx, esi
mov ebx, eax
call fcn.0040abe0
mov dword [edi + 4], ebx
mov eax, dword [ebx + 4]
mov dword [eax], ebx
mov eax, dword [esp + 0x38]
add eax, 0xfffffff0
mov byte [esp + 0x100], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e806
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x3c]
add eax, 0xfffffff0
mov byte [esp + 0x100], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e82e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov byte [esp + 0x100], 0
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e856
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x5c]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [esp + 0xf8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4