Function at 0x1003f96
Capabilities:
Get common file path
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xab0
mov eax, dword [0x100c004]
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
push edi
push 0x1001854
mov dword [ebp - 4], eax
mov dword [ebp - 0xa88], ebx
mov dword [ebp - 0xa7c], ebx
mov dword [ebp - 0xa90], ebx
mov dword [ebp - 0xa9c], ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
mov dword [ebp - 0xa84], eax
jne 0x1004000
mov dword [ebp - 0xa7c], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x100183c
call fcn.01002585
pop ecx
pop ecx
jmp 0x10045a2
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x1001820
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xa8c], eax
je 0x10041c5
push 0x1001804
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xa9c], eax
je 0x10041c5
push ebx
lea eax, [esi + 0x20]
push eax
lea eax, [ebp - 0xa90]
push eax
call dword [ebp - 0xa8c]
test eax, eax
jne 0x100406a
mov dword [ebp - 0xa7c], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x10017cc
jmp 0x1003ff4
mov eax, dword [esi + 0x30]
cmp eax, ebx
jl 0x1004598
cmp eax, 1
jle 0x1004180
cmp eax, 2
jne 0x1004598
push 0x10017b0
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xa8c], eax
je 0x10041c5
cmp dword [esi + 8], ebx
jbe 0x10045a2
mov eax, dword [esi + 4]
mov edi, ebx
shl edi, 2
push 0x10017a4
push dword [edi + eax]
call dword [sym.imp.msvcrt.dll_wcspbrk]
test eax, eax
pop ecx
pop ecx
je 0x10040da
mov eax, dword [esi + 4]
push dword [edi + eax]
inc dword [ebp - 0xa7c]
push 0x96a
jmp 0x100414c
cmp dword [esi + 0x4c], 0
je 0x10040f2
mov eax, dword [esi + 4]
push dword [edi + eax]
push 0x961
call fcn.010024f9
pop ecx
pop ecx
mov eax, dword [esi + 4]
push 0
push dword [edi + eax]
push dword [ebp - 0xa90]
call dword [ebp - 0xa8c]
test eax, eax
jne 0x1004153
inc dword [ebp - 0xa7c]
cmp dword [esi + 0x44], eax
jne 0x1004141
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x490
je 0x100412f
push eax
push 0x100176c
call fcn.01002585
jmp 0x100413f
mov eax, dword [esi + 4]
push dword [edi + eax]
push 0x96b
call fcn.01002459
pop ecx
pop ecx
mov eax, dword [esi + 4]
push dword [edi + eax]
push 0x968
call fcn.01002459
jmp 0x100416f
inc dword [ebp - 0xa88]
cmp dword [esi + 0x44], 0
jne 0x1004171
mov eax, dword [esi + 4]
push dword [edi + eax]
push 0x964
call fcn.010024f9
pop ecx
pop ecx
inc ebx
cmp ebx, dword [esi + 8]
jb 0x10040ab
jmp 0x10045a2
push 0x1001754
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xaa0], eax
je 0x10041c5
push 0x1001734
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xab0], eax
je 0x10041c5
push 0x1001710
push dword [ebp - 0xa84]
call edi
cmp eax, ebx
mov dword [ebp - 0xaa8], eax
jne 0x10041d9
mov dword [ebp - 0xa7c], 1
push 0x969
jmp 0x100459d
cmp dword [esi + 0x54], ebx
je 0x1004213
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0xf70]
mov ecx, dword fs:[0x18]
mov eax, dword [eax + 0x14c0]
mov ecx, dword [ecx + 0xf70]
mov dword [ecx + 0x14c0], 0x10016c8
mov dword [ecx + 0x14c4], ebx
mov dword [ebp - 0xaac], eax
cmp dword [esi + 8], ebx
mov dword [ebp - 0xa94], ebx
jbe 0x1004571
mov edi, dword [ebp - 0xa94]
mov eax, dword [esi + 4]
and dword [ebp - 0xaa4], 0
and dword [ebp - 0xa80], 0
shl edi, 2
push dword [edi + eax]
call dword [sym.imp.msvcrt.dll_wcslen]
test eax, eax
pop ecx
jbe 0x10042d9
mov eax, dword [esi + 4]
mov ebx, dword [ebp - 0xa80]
mov eax, dword [edi + eax]
push 1
add ebx, ebx
add eax, ebx
push 0x100168c
push eax
call dword [sym.imp.msvcrt.dll_wcsncmp]
add esp, 0xc
test eax, eax
je 0x10042ad
mov eax, dword [esi + 4]
mov eax, dword [edi + eax]
push 1
add eax, ebx
push 0x100143c
push eax
call dword [sym.imp.msvcrt.dll_wcsncmp]
add esp, 0xc
test eax, eax
je 0x10042ad
mov eax, dword [esi + 4]
mov eax, dword [edi + eax]
push 1
add eax, ebx
push 0x10016c4
push eax
call dword [sym.imp.msvcrt.dll_wcsncmp]
add esp, 0xc
test eax, eax
jne 0x10042ba
mov eax, dword [ebp - 0xa80]
inc eax
mov dword [ebp - 0xaa4], eax
mov eax, dword [esi + 4]
push dword [edi + eax]
inc dword [ebp - 0xa80]
call dword [sym.imp.msvcrt.dll_wcslen]
cmp dword [ebp - 0xa80], eax
pop ecx
jb 0x100424e
mov eax, dword [esi + 4]
push 0x104
push dword [edi + eax]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.msvcrt.dll_wcsncpy]
add esp, 0xc
lea eax, [ebp - 0x86c]
push eax
mov eax, dword [esi + 4]
xor ebx, ebx
mov word [ebp - 6], bx
push dword [edi + eax]
mov dword [ebp - 0xa98], ebx
call fcn.01009db7
cmp eax, 0xffffffff
mov dword [ebp - 0xa8c], eax
je 0x1004536
test byte [ebp - 0x86c], 0x10
jne 0x10044f3
mov eax, dword [ebp - 0xaa4]
inc dword [ebp - 0xa98]
mov ecx, 0x104
sub ecx, eax
push ecx
lea ecx, [ebp - 0x840]
push ecx
lea eax, [ebp + eax*2 - 0x20c]
push eax
call dword [sym.imp.msvcrt.dll_wcsncpy]
add esp, 0xc
lea eax, [ebp - 0x414]
push eax
mov word [ebp - 6], bx
call dword [sym.imp.SHLWAPI.dll_PathIsRelativeW]
test eax, eax
je 0x10043a5
lea eax, [ebp - 0x61c]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x10043b9
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
test eax, eax
je 0x10043b9
lea eax, [ebp - 0x61c]
jmp 0x10043ab
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCanonicalizeW]
cmp dword [esi + 0x54], ebx
je 0x10043dd
mov ecx, dword fs:[0x18]
mov ecx, dword [ecx + 0xf70]
lea eax, [ebp - 0x414]
mov dword [ecx + 0x14c0], eax
mov dword [ecx + 0x14c4], ebx
cmp dword [esi + 0x4c], ebx
je 0x10043f5
lea eax, [ebp - 0x20c]
push eax
push 0x960
call fcn.010024f9
pop ecx
pop ecx
cmp dword [esi + 0x30], ebx
push ebx
jne 0x1004404
lea eax, [ebp - 0x840]
push eax
jmp 0x1004405
push ebx
lea eax, [ebp - 0x414]
push eax
push dword [ebp - 0xa90]
call dword [ebp - 0xaa0]
cmp eax, ebx
mov dword [ebp - 0xa80], eax
jne 0x1004470
inc dword [ebp - 0xa7c]
cmp dword [esi + 0x44], ebx
jne 0x1004458
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb
je 0x1004445
push eax
push 0x1001694
call fcn.01002585
jmp 0x1004456
lea eax, [ebp - 0x20c]
push eax
push 0x96b
call fcn.01002459
pop ecx
pop ecx
lea eax, [ebp - 0x20c]
push eax
push 0x967
call fcn.01002459
pop ecx
pop ecx
jmp 0x10044f3
inc dword [ebp - 0xa88]
cmp dword [esi + 0x44], ebx
jne 0x10044e0
cmp dword [esi + 0x30], ebx
jne 0x1004495
lea eax, [ebp - 0x20c]
push eax
push 0x962
call fcn.010024f9
pop ecx
pop ecx
jmp 0x10044e0
push ebx
lea eax, [ebp - 0xa78]
push eax
push dword [ebp - 0xa80]
call dword [ebp - 0xab0]
test eax, eax
je 0x10044e0
lea eax, [ebp - 0xa74]
push 0x100168c
push eax
call dword [sym.imp.msvcrt.dll_wcsstr]
cmp eax, ebx
pop ecx
pop ecx
jne 0x10044cb
lea eax, [ebp - 0xa74]
push eax
lea eax, [ebp - 0x20c]
push eax
push 0x963
call fcn.010024f9
add esp, 0xc
push ebx
push dword [ebp - 0xa80]
push dword [ebp - 0xa90]
call dword [ebp - 0xaa8]
cmp dword [esi + 0x54], ebx
je 0x1004514
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0xf70]
mov dword [eax + 0x14c0], 0x10016c8
mov dword [eax + 0x14c4], ebx
lea eax, [ebp - 0x86c]
push eax
push dword [ebp - 0xa8c]
call fcn.01009e28
test eax, eax
jne 0x1004321
cmp dword [ebp - 0xa98], ebx
jne 0x1004550
mov eax, dword [esi + 4]
push dword [edi + eax]
inc dword [ebp - 0xa7c]
push 0x3ec
call fcn.01002459
pop ecx
pop ecx
jmp 0x100455c
push dword [ebp - 0xa8c]
call dword [sym.imp.KERNEL32.dll_FindClose]
inc dword [ebp - 0xa94]
mov eax, dword [ebp - 0xa94]
cmp eax, dword [esi + 8]
jb 0x1004222
cmp dword [esi + 0x54], 0
je 0x10045a2
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0xf70]
mov ecx, dword [ebp - 0xaac]
mov dword [eax + 0x14c0], ecx
and dword [eax + 0x14c4], 0
jmp 0x10045a2
push 0x3f0
call fcn.010023c5
xor edi, edi
cmp dword [esi + 0x4c], edi
jne 0x10045b6
cmp dword [esi + 0x44], edi
jne 0x100462a
cmp dword [ebp - 0xa7c], edi
je 0x100462a
push 0x1001690
call dword [sym.imp.msvcrt.dll_wprintf]
cmp dword [esi + 0x4c], edi
pop ecx
jne 0x10045cf
cmp dword [ebp - 0xa88], edi
je 0x100460b
mov eax, dword [esi + 0x30]
cmp eax, edi
jl 0x1004601
cmp eax, 1
jle 0x10045f4
cmp eax, 2
jne 0x1004601
push dword [ebp - 0xa88]
push 0x966
call fcn.010024f9
pop ecx
pop ecx
jmp 0x100460b
push dword [ebp - 0xa88]
push 0x965
jmp 0x10045eb
push 0x3f0
call fcn.010023c5
cmp dword [esi + 0x4c], edi
jne 0x1004618
cmp dword [ebp - 0xa7c], edi
je 0x100462a
push dword [ebp - 0xa7c]
push 0x7d1
call fcn.010024f9
pop ecx
pop ecx
cmp dword [ebp - 0xa9c], edi
je 0x100463f
push edi
push dword [ebp - 0xa90]
call dword [ebp - 0xa9c]
cmp dword [ebp - 0xa84], edi
je 0x1004653
push dword [ebp - 0xa84]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [ebp - 0xa7c], edi
jne 0x100467b
cmp dword [ebp - 0xa88], edi
je 0x1004667
xor eax, eax
jmp 0x100467e
push 0x7d3
call fcn.010023c5
push 0x3f0
call fcn.010023c5
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.010094f4
leave
ret 4