Function at 0x402440
Capabilities:
Get common file path

Disassembly:
sub esp, 0x37c
mov edx, str.runtime.system32
mov dword [esp + 0x36c], ebx
mov ebx, eax
mov dword [esp + 0x370], esi
mov esi, dword [sym.imp.ucrtbase.dll__wcsicmp]
mov dword [esp + 0x374], edi
mov dword [esp + 0x378], ebp
mov dword [esp + 4], edx
mov dword [esp], eax
call esi
test eax, eax
je 0x402492
mov dword [esp], ebx
mov eax, str.runtime.drivers
mov dword [esp + 4], eax
call esi
test eax, eax
jne 0x402590
mov eax, 0x25
mov dword [esp + 8], eax
lea edi, [esp + 0x158]
mov ecx, 1
mov dword [esp + 0xc], ecx
mov dword [esp + 4], edi
mov dword [esp], 0
call dword [sym.imp.shell32.dll_SHGetSpecialFolderPathW]
sub esp, 0x10
test eax, eax
je 0x402560
mov dword [esp], ebx
mov eax, str.runtime.inf
mov dword [esp + 4], eax
call esi
test eax, eax
jne 0x402520
mov dword [esp], edi
mov eax, str.inf
mov dword [esp + 4], eax
call dword [sym.imp.ucrtbase.dll_wcscat]
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll__wcsdup]
mov ebx, dword [esp + 0x36c]
mov esi, dword [esp + 0x370]
mov edi, dword [esp + 0x374]
mov ebp, dword [esp + 0x378]
add esp, 0x37c
ret
mov dword [esp], ebx
mov ebp, str.runtime.drivers
mov dword [esp + 4], ebp
call esi
test eax, eax
je 0x402570
mov dword [esp], ebx
mov edx, str.runtime.wbem
mov dword [esp + 4], edx
call esi
test eax, eax
jne 0x4024eb
mov dword [esp], edi
mov eax, str.wbem
mov dword [esp + 4], eax
call dword [sym.imp.ucrtbase.dll_wcscat]
jmp 0x4024eb
test byte [section..data], 2
jne 0x4025d0
xor eax, eax
jmp 0x4024f4
mov dword [esp], edi
mov ecx, str.drivers
mov dword [esp + 4], ecx
call dword [sym.imp.ucrtbase.dll_wcscat]
jmp 0x4024eb
mov dword [esp], ebx
mov eax, str.runtime.wbem
mov dword [esp + 4], eax
call esi
test eax, eax
je 0x402492
mov dword [esp], ebx
mov eax, str.runtime.windows
mov dword [esp + 4], eax
call esi
test eax, eax
jne 0x4026e8
mov eax, 0x24
jmp 0x402497
test ebx, ebx
je 0x4028a0
mov eax, ebx
shr eax, 0x10
je 0x402870
mov dword [esp], ebx
mov edx, 0xffffffff
mov dword [esp + 4], edx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
sub esp, 8
test eax, eax
jne 0x4026a8
cmp word [ebx], 0
je 0x4028aa
lea esi, [esi]
mov ebp, eax
cmp word [ebx + ebp*2 + 2], 0
lea eax, [eax + 1]
jne 0x402610
mov word [esp + 0x2c], 0x224c
lea ecx, [esp + 0x2e]
lea esi, [esp + 0x14e]
jmp 0x402675
cmp eax, 9
je 0x402838
cmp eax, 0xa
jne 0x4027da
mov word [ecx], 0x6e5c
add ecx, 2
lea esi, [esi]
lea esi, [esi]
lea eax, [ebp - 1]
test ebp, ebp
jle 0x402848
cmp ecx, esi
ja 0x402848
mov ebp, eax
movzx eax, word [ebx]
add ebx, 2
cmp eax, 0xd
je 0x4027c0
jbe 0x402638
cmp eax, 0x22
je 0x402828
cmp eax, 0x5c
jne 0x4027cd
mov word [ecx], 0x5c5c
add ecx, 2
jmp 0x402660
mov eax, 0x40a027
lea esi, [esi]
mov dword [esp + 0x10], eax
mov eax, str.Failed_to_get_folder_path_for__s_n
mov dword [esp + 0xc], eax
mov eax, str.lookup_expression
mov dword [esp + 8], eax
mov eax, section..data
mov dword [esp + 4], eax
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
xor eax, eax
jmp 0x4024f4
mov dword [esp], ebx
mov eax, str.runtime.inf
mov dword [esp + 4], eax
call esi
test eax, eax
je 0x4025bc
mov dword [esp], ebx
mov ebp, str.runtime.programfiles
mov dword [esp + 4], ebp
call esi
mov edx, eax
mov eax, 0x26
test edx, edx
je 0x402497
mov dword [esp], ebx
mov edi, str.runtime.commonfiles
mov dword [esp + 4], edi
call esi
mov edx, eax
mov eax, 0x2b
test edx, edx
je 0x402497
mov dword [esp + 4], str.runtime.programdata
mov dword [esp], ebx
call esi
mov edx, eax
mov eax, 0x23
test edx, edx
je 0x402497
mov dword [esp + 4], str.runtime.fonts
mov dword [esp], ebx
call esi
mov edx, eax
mov eax, 0x14
test edx, edx
je 0x402497
test byte [section..data], 1
je 0x402569
or edx, 0xffffffff
mov eax, ebx
call sym._wine_dbgstr_wn
mov dword [esp + 0xc], str.Unknown_expression__s_n
mov dword [esp + 8], str.lookup_expression
mov dword [esp + 4], 0x409000
mov dword [esp], 0
mov dword [esp + 0x10], eax
call sym._wine_dbg_log.constprop.0
xor eax, eax
jmp 0x4024f4
mov word [ecx], 0x725c
add ecx, 2
jmp 0x402660
lea edi, [eax - 0x20]
cmp di, 0x5e
jbe 0x402890
mov byte [ecx], 0x5c
mov edi, eax
add ecx, 5
shr edi, 0xc
movzx edx, byte [edi + str.0123456789abcdefcabinet_copy_file]
mov edi, eax
shr edi, 8
and edi, 0xf
mov byte [ecx - 4], dl
movzx edx, byte [edi + str.0123456789abcdefcabinet_copy_file]
mov edi, eax
shr edi, 4
and eax, 0xf
and edi, 0xf
movzx eax, byte [eax + str.0123456789abcdefcabinet_copy_file]
mov byte [ecx - 3], dl
movzx edx, byte [edi + str.0123456789abcdefcabinet_copy_file]
mov byte [ecx - 1], al
mov byte [ecx - 2], dl
jmp 0x402660
mov word [ecx], 0x225c
add ecx, 2
jmp 0x402660
mov word [ecx], 0x745c
add ecx, 2
jmp 0x402660
mov byte [ecx], 0x22
test eax, eax
jle 0x4028ba
mov word [ecx + 1], 0x2e2e
lea eax, [ecx + 4]
mov byte [ecx + 3], 0x2e
mov byte [eax], 0
lea eax, [esp + 0x2c]
mov dword [esp], eax
call sym.___wine_dbg_strdup
jmp 0x4026b0
mov dword [esp], 0x40a01a
movzx ebx, bx
mov dword [esp + 4], ebx
call sym._wine_dbg_sprintf.constprop.0
jmp 0x4026b0
mov byte [ecx], al
inc ecx
jmp 0x402660
mov eax, 0x40a020
jmp 0x4026b0
mov word [esp + 0x2c], 0x224c
lea ecx, [esp + 0x2e]
mov byte [esp + 0x2e], 0x22
lea eax, [ecx + 1]
jmp 0x40285c