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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1014
call fcn.005373d0
mov eax, dword [0x67e4d0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x1008], ecx
cmp dword [ebp + 8], 0
je 0x422ed9
cmp dword [ebp + 0xc], 0
jne 0x422ee0
xor eax, eax
jmp 0x4231a3
mov dword [ebp - 0x1014], 0
mov dword [ebp - 0x100c], 0
push 1
lea ecx, [ebp - 0x1004]
call fcn.004164b0
push 1
lea ecx, [ebp - 0x804]
call fcn.004164b0
lea ecx, [ebp - 0x1004]
call fcn.00416460
push eax
mov eax, dword [ebp + 0xc]
push eax
lea ecx, [ebp - 0x1004]
call fcn.00416470
push eax
call fcn.005a8679
add esp, 0xc
lea ecx, [ebp - 0x1004]
call fcn.00416470
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea ecx, [ebp - 0x1004]
call fcn.00416490
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x42315e
mov edx, dword [ebp + 0xc]
push edx
push str.Dest_File_Exist:__s
call fcn.0043d410
add esp, 8
mov eax, dword [ebp + 0xc]
push eax
call fcn.0043e3e0
add esp, 4
test eax, eax
jne 0x42315e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push str.Delete_File__s_Failed__error___d
call fcn.0043d410
add esp, 0xc
lea ecx, [ebp - 0x804]
call fcn.00416470
push eax
push 0
push 0x6513f8
lea ecx, [ebp - 0x1004]
call fcn.00416490
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
lea ecx, [ebp - 0x804]
call fcn.00416490
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [ebp - 0x804]
call fcn.00416490
push eax
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x4230a3
lea ecx, [ebp - 0x804]
call fcn.004167c0
push eax
mov eax, dword [ebp + 0xc]
push eax
push str.Rename_File__s_to__s_success
call fcn.0043d410
add esp, 0xc
push 4
push 0
lea ecx, [ebp - 0x804]
call fcn.00416490
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
lea ecx, [ebp - 0x804]
call fcn.004167c0
push eax
push str.delete_by_pending_file:_s
call fcn.0043d410
add esp, 8
cmp dword [ebp + 0x10], 0
je 0x423057
mov ecx, dword [ebp + 0x10]
mov dword [ecx], 4
mov dword [ebp - 0x100c], 1
mov edx, dword [ebp - 0x1008]
cmp dword [edx + 0x70], 0
jne 0x42309e
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x1008]
call fcn.00423660
test eax, eax
je 0x42309e
mov ecx, dword [ebp + 0xc]
push ecx
push 0x651400
call fcn.0043d410
add esp, 8
mov edx, dword [ebp - 0x1008]
mov dword [edx + 0x70], 1
jmp 0x42315e
mov eax, dword [ebp + 0xc]
push eax
push str.Rename_File__s_failed__replace_until_reboot
call fcn.0043d410
add esp, 8
push 0
lea ecx, [ebp - 0x804]
call fcn.00416490
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileW]
push 5
mov edx, dword [ebp + 0xc]
push edx
lea ecx, [ebp - 0x804]
call fcn.00416490
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
lea ecx, [ebp - 0x804]
call fcn.004167c0
push eax
mov eax, dword [ebp + 8]
push eax
push str.copy__s_to__s__replace_until_reboot
call fcn.0043d410
add esp, 0xc
cmp dword [ebp + 0x10], 0
je 0x423110
mov ecx, dword [ebp + 0x10]
mov dword [ecx], 5
mov dword [ebp - 0x100c], 1
mov edx, dword [ebp - 0x1008]
cmp dword [edx + 0x70], 0
jne 0x423157
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x1008]
call fcn.00423660
test eax, eax
je 0x423157
mov ecx, dword [ebp + 0xc]
push ecx
push str.check_file__s___need_reboot_now
call fcn.0043d410
add esp, 8
mov edx, dword [ebp - 0x1008]
mov dword [edx + 0x70], 1
mov eax, 1
jmp 0x4231a3
push 0
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x42319e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x1010], eax
mov edx, dword [ebp - 0x1010]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
push str.Copy_From__s_to__s_Failed_Error_Code___d
call fcn.0043d410
add esp, 0x10
xor eax, eax
jmp 0x4231a3
mov eax, 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00536569
mov esp, ebp
pop ebp
ret 0xc