Function at 0x4650fa
Capabilities:
Check if file exists
Delete directory
Delete file

Disassembly:
push ebp
sub esp, 0x25c
lea ebp, [esp - 4]
mov eax, dword [0x61f060]
xor eax, ebp
mov dword [ebp + 0x25c], eax
push 0xc
mov eax, 0x58426c
call fcn.0048905d
mov edi, dword [ebp + 0x268]
mov esi, ecx
lea eax, [esi + 4]
push eax
lea ecx, [ebp]
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], eax
call fcn.0040454a
xor ebx, ebx
lea eax, [ebp + 0x38]
push edi
push eax
mov dword [ebp - 4], ebx
mov byte [esi + 0x21], bl
mov byte [esi + 0x20], bl
mov byte [ebp - 0xd], bl
call fcn.004190eb
pop ecx
pop ecx
cmp dword [ebp + 0x4c], 0x104
mov byte [ebp - 4], 1
jae 0x4652d4
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x46516f
lea eax, [ebp + 0x3c]
mov edi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push eax
call edi
test eax, eax
je 0x4651e4
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x465188
lea eax, [ebp + 0x3c]
push ebx
push 0x80
push 4
push ebx
push 3
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4652d4
push dword [ebp - 0x18]
mov ecx, esi
call fcn.00465067
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 2
push ebx
push ebx
xor eax, eax
push eax
push edi
mov dword [esi], edi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov ecx, dword [ebp - 0x14]
push 0xffffffffffffffff
push ebx
lea eax, [ebp + 0x38]
push eax
call fcn.00404292
mov byte [ebp - 0xd], 1
jmp 0x4652d4
push ebx
lea ecx, [ebp + 0x1c]
mov dword [ebp + 0x34], 7
call fcn.00401848
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
mov byte [ebp - 4], 2
jae 0x465204
lea eax, [ebp + 0x3c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathIsFileSpecW]
test eax, eax
jne 0x465256
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x46521b
lea eax, [ebp + 0x3c]
push eax
lea eax, [ebp + 0x54]
push eax
call fcn.0048a31e
pop ecx
pop ecx
lea eax, [ebp + 0x54]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [ebp + 0x54]
push eax
call edi
test eax, eax
jne 0x465256
lea eax, [ebp + 0x54]
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
test eax, eax
jne 0x465256
lea eax, [ebp + 0x54]
push eax
lea ecx, [ebp + 0x1c]
call fcn.0040458d
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x465262
lea eax, [ebp + 0x3c]
push ebx
push 0x80
push 4
push ebx
push 3
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4652b1
mov ecx, dword [ebp - 0x14]
push 0xffffffffffffffff
push ebx
lea eax, [ebp + 0x38]
push eax
mov byte [esi + 0x20], 1
call fcn.00404292
push edi
mov byte [ebp - 0xd], 1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x4652aa
lea eax, [ebp + 0x3c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [ebp + 0x30], ebx
je 0x4652c9
cmp dword [ebp + 0x34], 8
mov eax, dword [ebp + 0x20]
jae 0x4652c2
lea eax, [ebp + 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
push ebx
push 1
lea ecx, [ebp + 0x1c]
call fcn.0040321f
push ebx
push 1
lea ecx, [ebp + 0x38]
call fcn.0040321f
push ebx
push 1
lea ecx, [ebp]
call fcn.0040321f
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x25c]
xor ecx, ebp
call fcn.00488a42
add ebp, 0x260
leave
ret 4