Function at 0x40a190
Capabilities:
Check if file exists
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49de28
mov eax, dword fs:[0]
push eax
sub esp, 0x164
mov eax, dword [0x4c8748]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x150], 0
mov dword [ebp - 0x14c], 0
call fcn.00409f60
cmp dword [edi + 0x5c], 8
lea esi, [edi + 0x48]
mov eax, esi
jb 0x40a1e5
mov eax, dword [esi]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40a4f8
push 0x70
lea eax, [ebp - 0x148]
push 0
push eax
call fcn.00478960
add esp, 0xc
lea ecx, [ebp - 0x148]
call fcn.0046c840
xorps xmm0, xmm0
mov dword [ebp - 4], 0
push 0
lea ecx, [ebp - 0x20]
movups xmmword [ebp - 0x20], xmm0
call fcn.00468f40
push 0xb8
lea eax, [ebp - 0xd8]
push 0
push eax
call fcn.00478960
add esp, 0xc
mov dword [ebp - 0xd8], 0x4a3d1c
push 0
lea eax, [ebp - 0xc8]
mov byte [ebp - 4], 2
xorps xmm0, xmm0
mov dword [ebp - 0x150], 1
push eax
lea ecx, [ebp - 0x68]
mov dword [ebp - 0x68], vtable.std::basic_istream_char__struct_std::char_traits_char__.0
mov dword [ebp - 0x6c], 0x58
movlpd qword [ebp - 0xd0], xmm0
call fcn.0040f7b0
mov eax, dword [ebp - 0xd8]
push 0
mov dword [ebp - 4], 4
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xd8], vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0xd8]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x70]
mov dword [ebp + ecx - 0xdc], eax
lea ecx, [ebp - 0xc8]
call fcn.00408660
cmp dword [esi + 0x14], 8
mov eax, esi
mov byte [ebp - 4], 5
jb 0x40a2cb
mov eax, dword [esi]
push 0x40
push 0x21
push eax
lea ecx, [ebp - 0xc8]
call fcn.0040fa10
test eax, eax
mov eax, dword [ebp - 0xd8]
mov ecx, dword [eax + 4]
jne 0x40a31d
xor eax, eax
cmp dword [ebp + ecx - 0xa0], eax
sete al
lea eax, [eax*4 + 2]
or eax, dword [ebp + ecx - 0xcc]
and eax, 0x17
mov dword [ebp + ecx - 0xcc], eax
mov ecx, dword [ebp + ecx - 0xc8]
and ecx, eax
jne 0x40a519
jmp 0x40a35a
xor edx, edx
mov eax, 4
cmp dword [ebp + ecx - 0xa0], edx
cmovne eax, edx
mov dword [ebp + ecx - 0xcc], eax
test dword [ebp + ecx - 0xc8], eax
je 0x40a35a
lea eax, [ebp - 0x154]
push 1
push eax
call fcn.0040f940
add esp, 8
push eax
push str.ios_base::badbit_set
jmp 0x40a548
push 0
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0xd8]
push eax
lea ecx, [ebp - 0x148]
call fcn.0046f8d0
test al, al
je 0x40a4c0
lea ecx, [ebp - 0x20]
call fcn.0046b1f0
test al, al
jne 0x40a4c0
cmp dword [ebp - 0x7c], 0
lea esi, [ebp - 0xc8]
jne 0x40a39a
xor esi, esi
jmp 0x40a3be
lea ecx, [ebp - 0xc8]
call fcn.0040ea60
push dword [ebp - 0x7c]
xor ecx, ecx
test al, al
cmove esi, ecx
call fcn.0047fb15
xor ecx, ecx
add esp, 4
test eax, eax
cmovne esi, ecx
push 2
push 0
lea ecx, [ebp - 0xc8]
call fcn.0040eb50
test esi, esi
jne 0x40a43d
mov eax, dword [ebp - 0xd8]
mov ecx, dword [eax + 4]
xor eax, eax
cmp dword [ebp + ecx - 0xa0], eax
sete al
lea eax, [eax*4 + 2]
or eax, dword [ebp + ecx - 0xcc]
and eax, 0x17
mov dword [ebp + ecx - 0xcc], eax
mov ecx, dword [ebp + ecx - 0xc8]
and ecx, eax
je 0x40a43d
test cl, 4
je 0x40a420
mov esi, str.ios_base::badbit_set
lea eax, [ebp - 0x170]
push 1
jmp 0x40a53d
test cl, 2
mov eax, str.ios_base::eofbit_set
mov esi, str.ios_base::failbit_set
cmove esi, eax
lea eax, [ebp - 0x170]
push 1
jmp 0x40a53d
lea eax, [ebp - 0x20]
mov ecx, edi
push eax
call fcn.0040a5e0
mov ecx, dword [ebp - 0xd8]
mov dword [ebp - 0x14c], eax
mov ecx, dword [ecx + 4]
mov dword [ebp + ecx - 0xd8], vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov ecx, dword [ebp - 0xd8]
mov edx, dword [ecx + 4]
lea ecx, [edx - 0x70]
mov dword [ebp + edx - 0xdc], ecx
lea ecx, [ebp - 0xc8]
call fcn.00408e50
mov eax, dword [ebp - 0xd8]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xd8], vtable.std::basic_istream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0xd8]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x18]
mov dword [ebp + ecx - 0xdc], eax
lea eax, [ebp - 0x68]
mov byte [ebp - 4], 6
push eax
mov dword [ebp - 0x68], vtable.std::ios_base.0
call fcn.00475d87
add esp, 4
jmp 0x40a4e5
lea ecx, [ebp - 0xd8]
call fcn.0040f280
cmp dword [esi + 0x14], 8
jb 0x40a4d3
mov esi, dword [esi]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [ebp - 0xd8]
call fcn.004094e0
lea ecx, [ebp - 0x20]
call fcn.00469340
lea ecx, [ebp - 0x148]
call fcn.004090c0
mov eax, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0047702f
mov esp, ebp
pop ebp
ret
test cl, 4
je 0x40a525
mov esi, str.ios_base::badbit_set
jmp 0x40a535
test cl, 2
mov esi, str.ios_base::failbit_set
mov eax, str.ios_base::eofbit_set
cmove esi, eax
push 1
lea eax, [ebp - 0x154]
push eax
call fcn.0040f940
add esp, 8
push eax
push esi
lea ecx, [ebp - 0x168]
call fcn.00408ae0
push 0x4bee4c
lea eax, [ebp - 0x168]
push eax
call fcn.00478aba
int3