Function at 0x4396c0
Capabilities:
Check if file exists
Delete file
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x629887
mov eax, dword fs:[0]
push eax
sub esp, 0xec0
mov eax, dword [0x6b278c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4396fe
jmp 0x439b8e
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov dword [ebp - 0x440], eax
cmp dword [ebp - 0x440], 0
je 0x43971c
jmp 0x439b8e
xor edx, edx
mov word [ebp - 0x64c], dx
push 0x206
push 0
lea eax, [ebp - 0x64a]
push eax
call fcn.005b4de0
add esp, 0xc
xor ecx, ecx
mov word [ebp - 0x85c], cx
push 0x206
push 0
lea edx, [ebp - 0x85a]
push edx
call fcn.005b4de0
add esp, 0xc
xor eax, eax
mov word [ebp - 0x43c], ax
push 0x206
push 0
lea ecx, [ebp - 0x43a]
push ecx
call fcn.005b4de0
add esp, 0xc
push 0x643238
lea ecx, [ebp - 0x2c]
call fcn.0040e4b0
mov dword [ebp - 4], 0
lea edx, [ebp - 0x85c]
push edx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp - 0x64c]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00438780
add esp, 8
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x878]
push eax
call fcn.00438850
add esp, 8
mov byte [ebp - 4], 1
push 3
push 0
lea ecx, [ebp - 0xec4]
push ecx
lea ecx, [ebp - 0x878]
call fcn.0041c700
mov dword [ebp - 0xec8], eax
mov edx, dword [ebp - 0xec8]
mov dword [ebp - 0xecc], edx
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0xecc]
call fcn.0040e5d0
push eax
push 0x64323c
lea eax, [ebp - 0x43c]
push eax
call fcn.005b50ec
add esp, 0xc
mov byte [ebp - 4], 1
lea ecx, [ebp - 0xec4]
call fcn.0040e530
push str.temp_
lea ecx, [ebp - 0x43c]
push ecx
call fcn.005b4d90
add esp, 8
lea edx, [ebp - 0x43c]
push edx
lea ecx, [ebp - 0x2c]
call fcn.0040e570
xor eax, eax
mov word [ebp - 0x234], ax
push 0x206
push 0
lea ecx, [ebp - 0x232]
push ecx
call fcn.005b4de0
add esp, 0xc
push 0x104
lea edx, [ebp - 0x234]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
mov dword [ebp - 0x87c], 0
push 0
movzx eax, word [ebp - 0x234]
push eax
lea ecx, [ebp - 0x2c]
call fcn.00431b20
mov dword [ebp - 0x880], eax
cmp dword [ebp - 0x880], 0
jne 0x4398ad
mov dword [ebp - 0x87c], 1
cmp dword [ebp - 0x87c], 0
jne 0x4398e7
lea ecx, [ebp - 0x43c]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4398e7
lea edx, [ebp - 0x43c]
push edx
call fcn.00432f80
add esp, 4
push 4
push 0
lea eax, [ebp - 0x43c]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov dword [ebp - 0x650], 0
mov dword [ebp - 0x884], 0
mov ecx, 1
test ecx, ecx
je 0x439b70
mov dword [ebp - 0x888], 1
xor edx, edx
mov word [ebp - 0xa94], dx
push 0x206
push 0
lea eax, [ebp - 0xa92]
push eax
call fcn.005b4de0
add esp, 0xc
xor ecx, ecx
mov word [ebp - 0xc9c], cx
push 0x206
push 0
lea edx, [ebp - 0xc9a]
push edx
call fcn.005b4de0
add esp, 0xc
cmp dword [ebp - 0x884], 0
jne 0x4399a4
lea eax, [ebp - 0x64c]
push eax
lea ecx, [ebp - 0x85c]
push ecx
push 0x643250
lea edx, [ebp - 0xa94]
push edx
call fcn.005b50ec
add esp, 0x10
lea eax, [ebp - 0x64c]
push eax
lea ecx, [ebp - 0x878]
call fcn.0040e5d0
push eax
push str._s_s.del
lea ecx, [ebp - 0xc9c]
push ecx
call fcn.005b50ec
add esp, 0x10
jmp 0x4399cd
mov edx, dword [ebp - 0x884]
push edx
lea eax, [ebp - 0x64c]
push eax
lea ecx, [ebp - 0x85c]
push ecx
push str._s_s.del_d
lea edx, [ebp - 0xa94]
push edx
call fcn.005b50ec
add esp, 0x14
lea eax, [ebp - 0xc9c]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.005ba017
add esp, 8
lea edx, [ebp - 0xa94]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x439a04
lea eax, [ebp - 0xa94]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov dword [ebp - 0x888], eax
cmp dword [ebp - 0x888], 0
jne 0x439a4d
cmp dword [ebp - 0x884], 0xa
jl 0x439a39
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x878]
call fcn.0040e530
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.0040e530
jmp 0x439b8e
mov ecx, dword [ebp - 0x884]
add ecx, 1
mov dword [ebp - 0x884], ecx
jmp 0x4398fb
cmp dword [ebp - 0x87c], 0
jne 0x439b02
xor edx, edx
mov word [ebp - 0xea4], dx
push 0x206
push 0
lea eax, [ebp - 0xea2]
push eax
call fcn.005b4de0
add esp, 0xc
lea ecx, [ebp - 0x2c]
call fcn.0040e5d0
push eax
push 0x643290
lea ecx, [ebp - 0x43c]
push ecx
call fcn.005b50ec
add esp, 0xc
lea edx, [ebp - 0xea4]
push edx
lea eax, [ebp - 0xc9c]
push eax
call fcn.00438780
add esp, 8
lea ecx, [ebp - 0xea4]
push ecx
lea edx, [ebp - 0x43c]
push edx
call fcn.005b4d90
add esp, 8
push 1
lea eax, [ebp - 0x43c]
push eax
lea ecx, [ebp - 0xc9c]
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov dword [ebp - 0xea8], eax
cmp dword [ebp - 0xea8], 0
je 0x439b02
lea edx, [ebp - 0x43c]
push edx
push 0x643298
lea eax, [ebp - 0xc9c]
push eax
call fcn.005b50ec
add esp, 0xc
push 3
lea ecx, [ebp - 0xa94]
push ecx
lea edx, [ebp - 0xc9c]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
lea eax, [ebp - 0xc9c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x439b3a
push 5
push 0
lea ecx, [ebp - 0xc9c]
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push 5
push 0
lea edx, [ebp - 0xa94]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x878]
call fcn.0040e530
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.0040e530
jmp 0x439b8e
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x878]
call fcn.0040e530
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.0040e530
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005b4b30
mov esp, ebp
pop ebp
ret