Function at 0x40392a
Capabilities:
Copy file
Delete directory
Print debug messages
Terminate process

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
push esi
push edi
call fcn.00405c1b
push 0x17
xor esi, esi
mov byte [esp + 0x17], 0
and dword [esp + 0x20], esi
mov ecx, 0x497520
pop edx
xor edi, edi
call fcn.00405ca4
call fcn.004056f9
mov ebx, eax
test ebx, ebx
jne 0x403972
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, str.CouldNotObtainExePath
jmp 0x403b24
mov ecx, ebx
call fcn.0040577a
mov edx, eax
mov dword [esp + 0x20], edx
test edx, edx
jne 0x403995
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, str.CouldNotObtainDirectory
jmp 0x403b24
xor eax, eax
xor ecx, ecx
mov dword [esp + 0x18], ecx
test eax, eax
jne 0x4039c8
mov ecx, dword [ecx + 0x497650]
call fcn.0040584b
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x20]
add ecx, 4
mov dword [esp + 0x18], ecx
cmp ecx, 0x1c
jb 0x40399d
test eax, eax
je 0x403acd
call fcn.00405907
mov dword [esp + 0x18], eax
test eax, eax
jne 0x4039e7
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, str.CreateTempDirFailed
jmp 0x403acd
mov ecx, ebx
call fcn.0040540a
mov dword [esp + 0x24], eax
test eax, eax
je 0x403a96
mov ecx, dword [esp + 0x18]
mov edx, eax
call fcn.0040504b
mov dword [esp + 0x14], eax
test eax, eax
je 0x403a49
push str.CopyFile..._n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringW]
push 1
push dword [esp + 0x18]
push ebx
call dword [sym.imp.KERNEL32.DLL_CopyFileW]
test eax, eax
jne 0x403a49
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edx, eax
mov ecx, str.CopyFile
call fcn.00405191
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.DLL_LocalFree]
and dword [esp + 0x14], esi
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.DLL_LocalFree]
mov eax, dword [esp + 0x14]
test eax, eax
je 0x403a96
mov edx, dword [esp + 0x18]
lea ecx, [esp + 0x1c]
push ecx
mov ecx, eax
call fcn.00405a41
mov byte [esp + 0x17], al
pop ecx
test al, al
jne 0x403a81
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, str.CreateProcessFailed
mov ecx, dword [esp + 0x14]
call fcn.00405bcd
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.DLL_LocalFree]
jmp 0x403aa3
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, str.CopyingFileFailed
push dword [esp + 0x18]
call dword [sym.imp.KERNEL32.DLL_RemoveDirectoryW]
test eax, eax
jne 0x403ac3
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edx, eax
mov ecx, str.RemoveDirectory
call fcn.00405191
push dword [esp + 0x18]
call dword [sym.imp.KERNEL32.DLL_LocalFree]
push dword [esp + 0x20]
call dword [sym.imp.KERNEL32.DLL_LocalFree]
test esi, esi
jne 0x403b24
push ebx
call dword [sym.imp.KERNEL32.DLL_LocalFree]
cmp byte [esp + 0x13], 0
je 0x403b00
cmp dword [esp + 0x1c], 0x103
jne 0x403afa
push esi
call dword [sym.imp.KERNEL32.DLL_ExitProcess]
push dword [esp + 0x1c]
jmp 0x403af4
push str.Will_continue_as_Launcher_App_in_this_process._n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringW]
push 0x32
pop edx
mov ecx, 0x497580
call fcn.00405ca4
call fcn.0045f95b
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
mov edx, ebx
mov ecx, esi
call fcn.004054d0
int3