Function at 0x400141a0
Capabilities:
Get common file path
Resolve function by parsing pe exports

Disassembly:
mov eax, 0x1274
call fcn.4001eac0
mov eax, dword [0x4006f01c]
xor eax, esp
mov dword [esp + 0x126c], eax
mov eax, dword [esp + 0x1278]
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1288]
mov dword [esp + 0x20], eax
mov eax, esi
mov dword [esp + 0x24], edx
push edi
mov dword [esp + 0x2c], ecx
lea edx, [eax + 2]
jmp 0x400141e0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x400141e0
sub eax, edx
sar eax, 1
mov edi, eax
mov dword [esp + 0x30], eax
xor ecx, ecx
lea eax, [edi + 5]
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
mov eax, dword [0x40477438]
push ecx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebp, eax
xor ebx, ebx
mov dword [esp + 0x1c], ebp
mov byte [esp + 0x17], 0
mov dword [esp + 0x20], 0x7d00
test ebp, ebp
jne 0x4001423a
mov eax, 0x7d05
jmp 0x400146e4
mov ecx, esi
mov eax, ebp
call fcn.400078c0
xor eax, eax
test edi, edi
jle 0x40014264
lea esp, [esp]
cmp word [ebp + eax*2], 0x5c
je 0x4001425f
inc eax
cmp eax, edi
jl 0x40014250
jmp 0x40014264
mov byte [esp + 0x17], 1
lea eax, [edi - 1]
test eax, eax
jl 0x40014283
jmp 0x40014270
cmp word [ebp + eax*2], 0x2e
je 0x4001427f
sub eax, 1
jns 0x40014270
jmp 0x40014283
lea ebx, [ebp + eax*2 + 2]
cmp byte [esp + 0x17], 0
jne 0x4001467a
test ebx, ebx
je 0x400142a6
mov edx, 0x4006c5e4
mov eax, ebx
call fcn.40007740
test eax, eax
jne 0x4001467a
mov byte [esp + 0x17], 0
test ebx, ebx
jne 0x40014307
lea ecx, [ebp + edi*2]
xor edx, edx
jmp 0x400142c0
inc edx
cmp word [edx*2 + str..DLL], 0
jne 0x400142c0
test ecx, ecx
je 0x40014300
mov esi, 0x2e
xor eax, eax
mov word [ecx], si
sub ecx, str..DLL
cmp eax, edx
jae 0x40014300
mov si, word [eax*2 + 0x4006c5da]
inc eax
mov word [ecx + eax*2 + str..DLL], si
cmp word [eax*2 + str..DLL], 0
jne 0x400142e0
add edi, 4
mov dword [esp + 0x30], edi
cmp dword [0x4047741c], 0
je 0x400144ab
cmp dword [0x40477420], 0
je 0x400144ab
push 0x40
lea ecx, [esp + 0x3c]
push 0
push ecx
call fcn.40001a40
add esp, 0xc
lea edx, [esp + 0x38]
push edx
push ebp
push 2
push 0
push 0
mov dword [esp + 0x4c], 0x40
call dword [0x40477420]
test eax, eax
je 0x400144ab
mov eax, dword [0x40477460]
mov ebx, dword [eax + 0x54]
mov esi, dword [esp + 0x24]
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esi + 8]
push 0x200
lea edi, [esp + 0x80]
mov edx, edi
push edx
lea eax, [esp + 0x68]
push eax
push ecx
call fcn.40015440
test eax, eax
jne 0x400143dc
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x400144ab
mov edx, dword [esp + 0x18]
mov eax, dword [0x40477438]
push edx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
test edi, edi
je 0x40014230
mov ecx, dword [0x40477460]
mov eax, dword [esp + 0x18]
mov ebx, dword [ecx + 0x54]
lea edx, [esp + 0x18]
push edx
mov edx, dword [esi + 8]
push eax
push edi
lea ecx, [esp + 0x68]
push ecx
push edx
call fcn.40015440
test eax, eax
je 0x40014487
mov ebp, dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
push 1
lea eax, [esp + 0x38]
push eax
call ebp
mov ecx, dword [edi + 0x3c]
mov edx, dword [esp + 0x30]
mov esi, eax
add ecx, esi
lea eax, [ecx + edx + 9]
mov dword [esp + 0x18], eax
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or eax, ecx
push eax
mov eax, dword [0x40477438]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, dword [esp + 0x2c]
mov dword [ebx], eax
test eax, eax
je 0x40014230
push esi
push eax
call ebp
mov ecx, dword [ebx]
dec esi
lea eax, [ecx + esi*2]
mov ecx, str.winsxs_
call fcn.400078c0
mov edx, dword [ebx]
mov ecx, dword [edi + 0x4c]
add esi, 8
lea eax, [edx + esi*2]
call fcn.400078c0
mov eax, dword [edi + 0x3c]
mov ecx, dword [ebx]
shr eax, 1
add esi, eax
lea eax, [ecx + esi*2]
mov ecx, 0x4006c600
call fcn.400078c0
mov eax, dword [ebx]
mov ecx, dword [esp + 0x1c]
inc esi
add esi, esi
add eax, esi
call fcn.400078c0
mov edx, dword [ebx]
mov eax, dword [esp + 0x28]
mov ebp, dword [esp + 0x1c]
add edx, esi
mov dword [eax], edx
mov bl, 1
jmp 0x4001448b
mov bl, byte [esp + 0x17]
lea ecx, [esp + 0x78]
cmp edi, ecx
je 0x400144a3
mov edx, dword [0x40477438]
push edi
push 0
push edx
call dword [sym.imp.KERNEL32.dll_HeapFree]
test bl, bl
jne 0x400146d1
mov ebx, dword [sym.imp.KERNEL32.dll_CreateFileW]
xor esi, esi
xor eax, eax
mov word [esp + 0x278], ax
mov eax, esi
sub eax, 0
je 0x4001451b
sub eax, 1
jne 0x40014541
push 0x800
lea ecx, [esp + 0x27c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, 0x800
jae 0x40014541
cmp word [esp + 0x278], 0
je 0x40014541
xor eax, eax
inc eax
cmp word [esp + eax*2 + 0x278], 0
jne 0x400144f0
push ebp
mov edx, 0x7ff
sub edx, eax
push 0x4006c610
push edx
lea ecx, [esp + eax*2 + 0x284]
call fcn.40007560
add esp, 0xc
jmp 0x40014541
mov eax, dword [esp + 0x24]
mov eax, dword [eax + 0x10]
test eax, eax
je 0x40014541
push ebp
push eax
push 0x4006c604
push 0x7ff
lea ecx, [esp + 0x288]
call fcn.40007560
add esp, 0x10
push 0
push 0
push 3
push 0
push 1
push 0x80000000
lea ecx, [esp + 0x290]
push ecx
call ebx
mov edi, eax
cmp edi, 0xffffffff
jne 0x40014570
inc esi
cmp esi, 6
jl 0x400144b3
jmp 0x400146d1
xor eax, eax
cmp word [esp + 0x278], ax
je 0x4001458c
lea esp, [esp]
inc eax
cmp word [esp + eax*2 + 0x278], 0
jne 0x40014580
xor ecx, ecx
inc eax
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
mov eax, dword [0x40477438]
push ecx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov si, word [esp + 0x278]
xor edx, edx
test si, si
je 0x400145cc
jmp 0x400145c0
inc edx
cmp word [esp + edx*2 + 0x278], 0
jne 0x400145c0
xor ecx, ecx
test eax, eax
je 0x40014619
mov word [eax], si
cmp word [esp + 0x278], cx
je 0x40014617
mov esi, eax
lea ebx, [esp + 0x278]
sub esi, ebx
lea ebx, [ebx]
cmp ecx, edx
jae 0x40014617
mov bp, word [esp + ecx*2 + 0x27a]
inc ecx
lea ebx, [esi + ecx*2]
mov word [esp + ebx + 0x278], bp
cmp word [esp + ecx*2 + 0x278], 0
mov ebp, dword [esp + 0x1c]
jne 0x400145f0
mov ecx, eax
mov edx, dword [esp + 0x2c]
mov dword [edx], ecx
test ecx, ecx
jne 0x40014635
mov eax, dword [esp + 0x28]
push edi
mov dword [eax], ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x400146d1
xor eax, eax
cmp word [ecx], ax
je 0x40014648
lea esp, [esp]
inc eax
cmp word [ecx + eax*2], 0
jne 0x40014640
lea ecx, [ecx + eax*2 - 2]
add eax, 0xffffffff
js 0x40014668
movzx edx, word [ecx]
cmp dx, 0x5c
je 0x40014668
cmp dx, 0x3a
je 0x40014668
dec eax
sub ecx, 2
test eax, eax
jge 0x40014651
mov eax, dword [esp + 0x28]
add ecx, 2
push edi
mov dword [eax], ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x400146d1
mov edi, dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
push 0
lea ecx, [esp + 0x28]
push ecx
push 2
push ebp
call edi
mov esi, eax
test esi, esi
je 0x400146c9
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
mov eax, dword [0x40477438]
push ecx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, dword [esp + 0x28]
mov ecx, dword [esp + 0x2c]
push edx
push eax
push esi
push ebp
mov dword [ecx], eax
call edi
test eax, eax
je 0x400146c9
cmp eax, esi
jle 0x400146d1
mov dword [esp + 0x20], 0x7d27
mov eax, dword [0x40477438]
push ebp
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x127c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.4001a06e
add esp, 0x1274
ret 8