Function at 0xd280710
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x620
mov eax, dword [0xd2b0418]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push edi
mov edi, edx
mov ebx, ecx
mov dword [ebp - 0x620], eax
test edi, edi
je 0xd2808bd
cmp word [edi], 0
je 0xd2808bd
push 0xd271a78
push edi
call dword [sym.imp.msvcrt.dll_wcspbrk]
add esp, 8
test eax, eax
je 0xd280831
push edi
call fcn.0d29dcc0
test eax, eax
je 0xd280794
test esi, esi
je 0xd28091a
mov ax, word [ebp + 8]
test ax, ax
jbe 0xd28091a
push edi
movzx ecx, ax
push 0xd27191c
push ecx
push esi
call sub.msvcrt.dll_swprintf_s
add esp, 0x10
jmp 0xd28091a
push 0x101
lea eax, [ebp - 0x414]
push eax
push 0x104
lea ecx, [ebp - 0x61c]
push ecx
push 0x101
lea edx, [ebp - 0x210]
push edx
push 4
lea eax, [ebp - 0xc]
push eax
push edi
call sub.msvcrt.dll__wsplitpath_s
add esp, 0x24
test esi, esi
je 0xd2807f1
mov ax, word [ebp + 8]
test ax, ax
jbe 0xd2807f1
lea ecx, [ebp - 0x210]
push ecx
lea edx, [ebp - 0xc]
push edx
movzx eax, ax
push 0xd271a60
push eax
push esi
call sub.msvcrt.dll_swprintf_s
add esp, 0x14
mov eax, dword [ebp - 0x620]
test eax, eax
je 0xd280941
mov cx, word [ebp + 0x10]
test cx, cx
jbe 0xd280941
lea edx, [ebp - 0x414]
push edx
lea edx, [ebp - 0x61c]
push edx
movzx ecx, cx
push 0xd271a60
push ecx
push eax
call sub.msvcrt.dll_swprintf_s
add esp, 0x14
jmp 0xd280930
mov ebx, dword [ebx + 0x2c]
test ebx, ebx
je 0xd28085f
cmp word [ebx], 0
je 0xd28085f
test esi, esi
je 0xd28088e
mov ax, word [ebp + 8]
test ax, ax
jbe 0xd28088e
movzx eax, ax
lea edx, [eax - 1]
push edx
push ebx
push eax
push esi
call sub.msvcrt.dll_wcsncpy_s
add esp, 0x10
jmp 0xd28088e
test esi, esi
je 0xd28088e
cmp word [ebp + 8], 0
jbe 0xd28088e
movzx ebx, word [ebp + 8]
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x7e
push esi
call dword [sym.imp.msvcrt.dll_wcschr]
add esp, 8
test eax, eax
je 0xd28088e
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
mov ecx, dword [ebp - 0x620]
test ecx, ecx
je 0xd280941
mov ax, word [ebp + 0x10]
test ax, ax
jbe 0xd280941
movzx eax, ax
lea edx, [eax - 1]
push edx
push edi
push eax
push ecx
call sub.msvcrt.dll_wcsncpy_s
add esp, 0x10
jmp 0xd280930
mov ebx, dword [ebx + 0x2c]
test ebx, ebx
je 0xd2808eb
cmp word [ebx], 0
je 0xd2808eb
test esi, esi
je 0xd28091a
mov ax, word [ebp + 8]
test ax, ax
jbe 0xd28091a
movzx eax, ax
lea ecx, [eax - 1]
push ecx
push ebx
push eax
push esi
call sub.msvcrt.dll_wcsncpy_s
add esp, 0x10
jmp 0xd28091a
test esi, esi
je 0xd28091a
cmp word [ebp + 8], 0
jbe 0xd28091a
movzx edi, word [ebp + 8]
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x7e
push esi
call dword [sym.imp.msvcrt.dll_wcschr]
add esp, 8
test eax, eax
je 0xd28091a
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
mov eax, dword [ebp - 0x620]
test eax, eax
je 0xd280941
cmp word [ebp + 0x10], 0
jbe 0xd280941
xor edx, edx
mov word [eax], dx
movzx eax, word [ebp + 0x10]
mov edx, dword [ebp - 0x620]
xor ecx, ecx
mov word [edx + eax*2 - 2], cx
pop edi
pop ebx
test esi, esi
je 0xd28095a
mov ax, word [ebp + 8]
test ax, ax
jbe 0xd28095a
movzx eax, ax
xor ecx, ecx
mov word [esi + eax*2 - 2], cx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0d2a6cd9
mov esp, ebp
pop ebp
ret 0xc