Function at 0x40c250
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x424d30
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x188
push esi
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
push 0
push 0
lea ecx, [ebp - 0x38]
call fcn.00406627
mov dword [ebp - 4], 0
cmp dword [ebp + 0xc], 0
jne 0x40c356
lea eax, [ebp - 0x194]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je 0x40c2f0
movsx ecx, byte [ebp - 0x194]
test ecx, ecx
jne 0x40c2cb
mov dword [ebp - 0x4c], 0
jmp 0x40c2dd
lea edx, [ebp - 0x194]
push edx
call fcn.00418020
add esp, 4
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x194]
push ecx
lea ecx, [ebp - 0x38]
call fcn.0040644a
cmp dword [ebp - 0x24], 0x10
jb 0x40c307
mov edx, dword [ebp - 0x84]
mov dword [ebp - 0x44], edx
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x44], eax
jmp 0x40c30d
lea ecx, [ebp - 0x38]
mov dword [ebp - 0x44], ecx
push 1
mov edx, dword [ebp - 0x44]
push edx
call fcn.0040d000
add esp, 8
movzx eax, al
test eax, eax
jne 0x40c354
mov ecx, dword [ebp + 0x10]
movsx edx, byte [ecx]
test edx, edx
jne 0x40c335
mov dword [ebp - 0x54], 0
jmp 0x40c344
mov eax, dword [ebp + 0x10]
push eax
call fcn.00418020
add esp, 4
mov dword [ebp - 0x54], eax
mov ecx, dword [ebp - 0x54]
push ecx
mov edx, dword [ebp + 0x10]
push edx
lea ecx, [ebp - 0x38]
call fcn.0040644a
jmp 0x40c388
mov eax, dword [ebp + 0xc]
movsx ecx, byte [eax]
test ecx, ecx
jne 0x40c369
mov dword [ebp - 0x58], 0
jmp 0x40c378
mov edx, dword [ebp + 0xc]
push edx
call fcn.00418020
add esp, 4
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x58]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
lea ecx, [ebp - 0x38]
call fcn.0040644a
cmp dword [ebp - 0x28], 0
jne 0x40c397
mov dword [ebp - 0x48], 1
jmp 0x40c39e
mov dword [ebp - 0x48], 0
movzx edx, byte [ebp - 0x48]
test edx, edx
jne 0x40c413
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x24], 0x10
jb 0x40c3c0
mov ecx, dword [ebp - 0x7c]
mov dword [ebp - 0x1c], ecx
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x1c], edx
jmp 0x40c3c6
lea eax, [ebp - 0x38]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
add ecx, dword [ebp - 0x5c]
movsx edx, byte [ecx - 1]
cmp edx, 0x5c
je 0x40c413
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x60], eax
cmp dword [ebp - 0x24], 0x10
jb 0x40c3f2
mov ecx, dword [ebp - 0x8c]
mov dword [ebp - 0x40], ecx
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x40], edx
jmp 0x40c3f8
lea eax, [ebp - 0x38]
mov dword [ebp - 0x40], eax
mov ecx, dword [ebp - 0x40]
add ecx, dword [ebp - 0x60]
movsx edx, byte [ecx - 1]
cmp edx, 0x2f
je 0x40c413
push 0x5c
push 1
lea ecx, [ebp - 0x38]
call fcn.0040f000
mov dword [ebp - 0x14], 0
jmp 0x40c425
mov eax, dword [ebp - 0x14]
add eax, 1
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0x200
jge 0x40c544
cmp dword [ebp - 0x24], 0x10
jb 0x40c449
mov ecx, dword [ebp - 0x90]
mov dword [ebp - 0x18], ecx
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x18], edx
jmp 0x40c44f
lea eax, [ebp - 0x38]
mov dword [ebp - 0x18], eax
call fcn.00418330
mov esi, eax
and esi, 0xffff
shl esi, 0x10
call fcn.00418330
or esi, eax
push esi
mov ecx, dword [ebp - 0x18]
push ecx
push str._spl_08x.ftf
lea edx, [ebp - 0x78]
push edx
call fcn.0040cbc0
add esp, 0x10
mov byte [ebp - 4], 1
cmp dword [ebp - 0x64], 0x10
jb 0x40c497
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x78]
mov dword [ebp - 0x20], ecx
jmp 0x40c49d
lea edx, [ebp - 0x78]
mov dword [ebp - 0x20], edx
mov eax, dword [ebp - 0x20]
push eax
call fcn.0040ca20
add esp, 4
cmp dword [ebp - 0x64], 0x10
jb 0x40c4bd
mov ecx, dword [ebp - 0x80]
mov dword [ebp - 0x3c], ecx
mov edx, dword [ebp - 0x78]
mov dword [ebp - 0x3c], edx
jmp 0x40c4c3
lea eax, [ebp - 0x78]
mov dword [ebp - 0x3c], eax
push 0
push 0x80
push 1
push 0
push 0
push 0xc0000000
mov ecx, dword [ebp - 0x3c]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x50], eax
cmp dword [ebp - 0x50], 0xffffffff
je 0x40c52f
mov edx, dword [ebp - 0x50]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x78]
push eax
mov ecx, dword [ebp + 8]
call fcn.00409e94
mov ecx, dword [ebp - 0x10]
or ecx, 1
mov dword [ebp - 0x10], ecx
mov byte [ebp - 4], 0
push 0
push 1
lea ecx, [ebp - 0x78]
call fcn.00406627
mov dword [ebp - 4], 0xffffffff
push 0
push 1
lea ecx, [ebp - 0x38]
call fcn.00406627
mov eax, dword [ebp + 8]
jmp 0x40c583
mov byte [ebp - 4], 0
push 0
push 1
lea ecx, [ebp - 0x78]
call fcn.00406627
jmp 0x40c41c
mov edx, dword [ebp + 8]
mov dword [edx + 0x10], 0
mov eax, dword [ebp + 8]
mov dword [eax + 0x14], 0
push 0
push 0
mov ecx, dword [ebp + 8]
call fcn.00406627
mov ecx, dword [ebp - 0x10]
or ecx, 1
mov dword [ebp - 0x10], ecx
mov dword [ebp - 4], 0xffffffff
push 0
push 1
lea ecx, [ebp - 0x38]
call fcn.00406627
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop esi
mov esp, ebp
pop ebp
ret