Function at 0x1003e5e0
Capabilities:
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x10101161
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x144
mov eax, dword [esp + 0x158]
push ebx
push ebp
push esi
push edi
mov esi, ecx
push eax
lea ecx, [esp + 0x18]
xor ebp, ebp
push ecx
mov dword [esp + 0x30], esi
mov dword [esp + 0x2c], ebp
call fcn.100576d0
mov edx, dword [esp + 0x1c]
or ebx, 0xffffffff
xor eax, eax
mov edi, 0x10116df4
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0x10116df4
push edx
push ebp
lea ecx, [esp + 0x24]
mov dword [esp + 0x16c], ebp
call fcn.100032a5
cmp eax, ebp
jne 0x1003e695
mov esi, dword [esp + 0x164]
mov al, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], al
call fcn.10002047
xor eax, eax
mov edi, str.Intel
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Intel
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
xor eax, eax
mov edi, 0x10116de8
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [esp + 0x20]
push 0x10116de8
push ecx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003e9aa
mov eax, dword [esi + 0x80]
add eax, 0xfffffffd
cmp eax, 3
ja case.default.0x1003e6d2
jmp dword [eax*4 + 0x1003ef38]
cmp dword [esi + 0x84], 0x33
jne case.default.0x1003e6d2
mov esi, dword [esp + 0x164]
mov dl, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], dl
call fcn.10002047
xor eax, eax
mov edi, str.Windows_NT_3.1
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_NT_3.1
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov eax, dword [esi + 0x84]
cmp eax, ebp
je 0x1003e7d7
cmp eax, 0xa
je 0x1003e790
cmp eax, 0x5a
jne case.default.0x1003e6d2
mov esi, dword [esp + 0x164]
mov al, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], al
call fcn.10002047
xor eax, eax
mov edi, str.Windows_ME
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_ME
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov esi, dword [esp + 0x164]
mov cl, byte [esp + 0x13]
mov byte [esi], cl
push ebp
mov ecx, esi
call fcn.10002047
xor eax, eax
mov edi, str.Windows_98
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_98
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov esi, dword [esp + 0x164]
mov dl, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], dl
call fcn.10002047
xor eax, eax
mov edi, str.Windows_95
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_95
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov eax, dword [esi + 0x84]
sub eax, ebp
je 0x1003e8c4
dec eax
je 0x1003e87d
dec eax
jne case.default.0x1003e6d2
mov esi, dword [esp + 0x164]
mov al, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], al
call fcn.10002047
xor eax, eax
mov edi, str.Windows_Server_2003
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_Server_2003
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov esi, dword [esp + 0x164]
mov cl, byte [esp + 0x13]
mov byte [esi], cl
push ebp
mov ecx, esi
call fcn.10002047
xor eax, eax
mov edi, str.Windows_XP
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_XP
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov esi, dword [esp + 0x164]
mov dl, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], dl
call fcn.10002047
xor eax, eax
mov edi, str.Windows_2000
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_2000
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov eax, dword [esi + 0x84]
sub eax, ebp
je 0x1003e963
dec eax
jne case.default.0x1003e6d2
mov esi, dword [esp + 0x164]
mov al, byte [esp + 0x13]
push ebp
mov ecx, esi
mov byte [esi], al
call fcn.10002047
xor eax, eax
mov edi, str.Windows_7
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_7
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov esi, dword [esp + 0x164]
mov cl, byte [esp + 0x13]
mov byte [esi], cl
push ebp
mov ecx, esi
call fcn.10002047
xor eax, eax
mov edi, str.Windows_Vista
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.Windows_Vista
mov ecx, esi
call fcn.10002275
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], ebx
call fcn.10002047
jmp 0x1003ef18
mov edx, dword [esp + 0x1c]
xor eax, eax
mov edi, str.appdir
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.appdir
push edx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003eafd
push 0x104
lea eax, [esp + 0x50]
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je case.default.0x1003e6d2
mov cl, byte [esp + 0x13]
mov byte [esp + 0x2c], cl
push ebp
lea ecx, [esp + 0x30]
call fcn.10002047
xor eax, eax
lea edi, [esp + 0x4c]
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebp, ecx
push 1
push ebp
lea ecx, [esp + 0x34]
call fcn.10002311
test al, al
je 0x1003ea41
mov edi, dword [esp + 0x30]
mov ecx, ebp
mov edx, ecx
shr ecx, 2
lea esi, [esp + 0x4c]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push ebp
lea ecx, [esp + 0x30]
call fcn.100040f0
mov eax, dword [0x10105430]
push 1
push eax
lea eax, [esp + 0x1b]
push eax
lea ecx, [esp + 0x38]
mov byte [esp + 0x168], 1
mov byte [esp + 0x1f], 0x5c
call fcn.1001c140
cmp eax, dword [0x10105430]
je 0x1003eaab
push eax
push 0
lea ecx, [esp + 0x44]
push ecx
lea ecx, [esp + 0x38]
call fcn.10001bf3
mov edx, dword [0x10105430]
push edx
push 0
push eax
lea ecx, [esp + 0x38]
mov byte [esp + 0x168], 2
call fcn.10001ecb
push 1
lea ecx, [esp + 0x40]
mov byte [esp + 0x160], 1
call fcn.10002047
mov al, byte [esp + 0x2c]
sub esp, 0x10
mov esi, esp
mov dword [esp + 0x34], esp
push 0
mov ecx, esi
mov byte [esi], al
call fcn.10002047
mov ecx, dword [0x10105430]
push ecx
push 0
lea edx, [esp + 0x44]
push edx
mov ecx, esi
call fcn.10001ecb
mov esi, dword [esp + 0x174]
push esi
call fcn.1003ef50
push 1
lea ecx, [esp + 0x30]
mov byte [esp + 0x160], 0
call fcn.10002047
jmp 0x1003e67e
xor eax, eax
mov edi, str.apphwnd
mov ecx, ebx
repne scasb al, byte es:[edi]
mov eax, dword [esp + 0x1c]
not ecx
dec ecx
push ecx
push str.apphwnd
push eax
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003eb39
mov ecx, dword [esi]
mov esi, dword [esp + 0x164]
push ecx
push esi
call fcn.10056fb0
jmp 0x1003e67e
mov edx, dword [esp + 0x1c]
xor eax, eax
mov edi, str.apphinstance
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.apphinstance
push edx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003eb76
mov eax, dword [esi + 4]
mov esi, dword [esp + 0x164]
push eax
push esi
call fcn.10056fb0
jmp 0x1003e67e
xor eax, eax
mov edi, str.windowsdir
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [esp + 0x20]
push str.windowsdir
push ecx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003ec14
push 0x104
lea edx, [esp + 0x50]
push edx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
je case.default.0x1003e6d2
mov al, byte [esp + 0x13]
sub esp, 0x10
mov ebp, esp
mov dword [esp + 0x34], esp
push 0
mov ecx, ebp
mov byte [ebp], al
call fcn.10002047
or ecx, 0xffffffff
xor eax, eax
lea edi, [esp + 0x5c]
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebx, ecx
push 1
push ebx
mov ecx, ebp
call fcn.10002311
test al, al
je 0x1003ed4f
mov edi, dword [ebp + 4]
mov ecx, ebx
mov edx, ecx
shr ecx, 2
lea esi, [esp + 0x5c]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push ebx
mov ecx, ebp
call fcn.100040f0
jmp 0x1003ed4f
xor eax, eax
mov edi, str.systemdir
mov ecx, ebx
repne scasb al, byte es:[edi]
mov eax, dword [esp + 0x1c]
not ecx
dec ecx
push ecx
push str.systemdir
push eax
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003ecb2
push 0x104
lea ecx, [esp + 0x50]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je case.default.0x1003e6d2
mov dl, byte [esp + 0x13]
sub esp, 0x10
mov ebp, esp
mov dword [esp + 0x34], esp
push 0
mov ecx, ebp
mov byte [ebp], dl
call fcn.10002047
or ecx, 0xffffffff
xor eax, eax
lea edi, [esp + 0x5c]
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebx, ecx
push 1
push ebx
mov ecx, ebp
call fcn.10002311
test al, al
je 0x1003ed4f
mov edi, dword [ebp + 4]
mov ecx, ebx
mov eax, ecx
shr ecx, 2
lea esi, [esp + 0x5c]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push ebx
mov ecx, ebp
call fcn.100040f0
jmp 0x1003ed4f
xor eax, eax
mov edi, str.tempdir
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [esp + 0x20]
push str.tempdir
push ecx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003ed77
lea edx, [esp + 0x4c]
push edx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je case.default.0x1003e6d2
mov al, byte [esp + 0x13]
sub esp, 0x10
mov ebp, esp
mov dword [esp + 0x34], esp
push 0
mov ecx, ebp
mov byte [ebp], al
call fcn.10002047
or ecx, 0xffffffff
xor eax, eax
lea edi, [esp + 0x5c]
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebx, ecx
push 1
push ebx
mov ecx, ebp
call fcn.10002311
test al, al
je 0x1003ed4f
mov edi, dword [ebp + 4]
mov ecx, ebx
mov edx, ecx
shr ecx, 2
lea esi, [esp + 0x5c]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp + 8], ebx
mov ebp, dword [ebp + 4]
add ebp, ebx
mov byte [ebp], 0
mov esi, dword [esp + 0x174]
push esi
call fcn.1003ef50
push 1
lea ecx, [esp + 0x18]
mov dword [esp + 0x160], 0xffffffff
call fcn.10002047
jmp 0x1003ef18
xor eax, eax
mov edi, str.direct3d7
mov ecx, ebx
repne scasb al, byte es:[edi]
mov eax, dword [esp + 0x1c]
not ecx
dec ecx
push ecx
push str.direct3d7
push eax
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
cmp eax, ebp
jne 0x1003edbf
mov eax, dword [esi + 0x10]
cmp eax, ebp
je case.default.0x1003e6d2
mov ecx, dword [eax + 8]
mov esi, dword [esp + 0x164]
push ecx
push esi
call fcn.10056fb0
jmp 0x1003e67e
mov edx, dword [esp + 0x1c]
xor eax, eax
mov edi, str.direct3ddevice7
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.direct3ddevice7
push edx
push ebp
lea ecx, [esp + 0x24]
call fcn.100032a5
test eax, eax
jne 0x1003ee0d
mov eax, dword [esi + 0x10]
cmp eax, ebp
je case.default.0x1003e6d2
mov eax, dword [eax + 0xc]
mov esi, dword [esp + 0x164]
push eax
push esi
call fcn.10056fb0
mov ecx, dword [esp + 0x18]
cmp ecx, ebp
jmp 0x1003eefa
mov edx, dword [esp + 0x1c]
xor eax, eax
mov edi, str.directdraw7
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebp, ecx
cmp edx, ebp
mov ecx, edx
jb 0x1003ee29
mov ecx, ebp
mov ebx, dword [esp + 0x18]
mov edi, str.directdraw7
mov esi, ebx
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x1003ee3f
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x1003ee60
cmp edx, ebp
jb 0x1003ee60
cmp edx, ebp
setne al
test eax, eax
jne 0x1003ee60
mov ecx, dword [esp + 0x28]
mov eax, dword [ecx + 0x10]
test eax, eax
je case.default.0x1003e6d2
mov edx, dword [eax]
push edx
jmp 0x1003eeab
or ecx, 0xffffffff
xor eax, eax
mov edi, str.directinput7
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebp, ecx
cmp edx, ebp
mov ecx, edx
jb 0x1003ee79
mov ecx, ebp
mov edi, str.directinput7
mov esi, ebx
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x1003ee8b
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne case.default.0x1003e6d2
cmp edx, ebp
jb case.default.0x1003e6d2
cmp edx, ebp
setne al
test eax, eax
jne case.default.0x1003e6d2
mov eax, dword [esp + 0x28]
mov eax, dword [eax + 0xc]
test eax, eax
je case.default.0x1003e6d2
mov ecx, dword [eax + 4]
push ecx
mov esi, dword [esp + 0x168]
push esi
call fcn.10056fb0
mov ecx, dword [esp + 0x18]
test ecx, ecx
jmp 0x1003eefa
mov esi, dword [esp + 0x164]
mov dl, byte [esp + 0x13]
xor ebx, ebx
or ecx, 0xffffffff
xor eax, eax
mov byte [esi], dl
mov dword [esi + 4], ebx
mov dword [esi + 8], ebx
mov dword [esi + 0xc], ebx
mov edi, 0x101314ac
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0x101314ac
mov ecx, esi
call fcn.10002275
mov ecx, dword [esp + 0x18]
cmp ecx, ebx
je 0x1003ef18
mov al, byte [ecx - 1]
test al, al
je 0x1003ef0e
cmp al, 0xff
je 0x1003ef0e
dec al
mov byte [ecx - 1], al
jmp 0x1003ef18
dec ecx
push ecx
call fcn.10090902
add esp, 4
mov ecx, dword [esp + 0x154]
pop edi
mov eax, esi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x150
ret 8