Function at 0x40321d
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [ebp + 0xc]
xor eax, eax
and dword [ebp - 8], eax
xor ecx, ecx
test byte [ebp + 0x10], 1
push esi
push edi
push 0x40
mov dword [ebp - 4], eax
mov dword [ebp - 0xc], ecx
pop edi
je 0x40334a
push edi
lea eax, [ebp - 4]
mov dword [ebp - 0xc], edi
push eax
call fcn.00401f76
mov esi, eax
test esi, esi
js 0x403464
push dword [ebp - 0xc]
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
jne 0x40329e
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push pe_nt_image_headers32
push str.c:jworkspacewix3_build5059eb25_srclibsdutilpathutil.cpp
call fcn.00403970
jmp 0x403464
mov ecx, dword [ebp - 0xc]
cmp ecx, eax
jae 0x403309
push eax
mov dword [ebp - 0xc], eax
lea eax, [ebp - 4]
push eax
call fcn.00401f76
mov esi, eax
test esi, esi
js 0x403464
push dword [ebp - 0xc]
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
jne 0x4032f3
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x113
jmp 0x40328f
mov ecx, dword [ebp - 0xc]
cmp ecx, eax
jae 0x403309
mov eax, 0x8007007a
push eax
mov esi, eax
push 0x118
jmp 0x40328f
cmp eax, 0x104
jbe 0x403347
lea eax, [ebp - 4]
push eax
call fcn.00403735
mov esi, eax
xor eax, eax
cmp esi, 0x80070057
cmove esi, eax
test esi, esi
js 0x403464
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 4]
call fcn.004027eb
mov esi, eax
test esi, esi
js 0x403464
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
test byte [ebp + 0x10], 2
je 0x40344b
and dword [ebp + 0x10], 0
mov edx, ebx
test eax, eax
cmovne edx, eax
cmp ecx, edi
lea eax, [ebp - 8]
mov dword [ebp + 0xc], edx
cmova edi, ecx
push edi
push eax
call fcn.00401f76
mov esi, eax
test esi, esi
js 0x403464
lea eax, [ebp + 0x10]
push eax
push dword [ebp - 8]
push edi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
test eax, eax
jne 0x4033b9
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x139
jmp 0x40328f
cmp edi, eax
jae 0x403430
cmp eax, 0x104
lea edi, [eax + 7]
cmovb edi, eax
lea eax, [ebp - 8]
push edi
push eax
call fcn.00401f76
mov esi, eax
test esi, esi
js 0x403464
lea eax, [ebp + 0x10]
push eax
push dword [ebp - 8]
push edi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
test eax, eax
jne 0x40341a
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x144
jmp 0x40328f
cmp edi, eax
jae 0x403430
mov eax, 0x8007007a
push eax
mov esi, eax
push 0x149
jmp 0x40328f
cmp eax, 0x104
jbe 0x403446
lea eax, [ebp - 8]
push eax
call fcn.00403735
mov esi, eax
test esi, esi
js 0x403464
mov eax, dword [ebp - 8]
jmp 0x403452
and dword [ebp - 4], 0
mov dword [ebp - 8], eax
test eax, eax
push 0
cmovne ebx, eax
push ebx
push dword [ebp + 8]
call fcn.0040224f
mov esi, eax
cmp dword [ebp - 8], 0
je 0x403472
push dword [ebp - 8]
call fcn.00402706
cmp dword [ebp - 4], 0
je 0x403480
push dword [ebp - 4]
call fcn.00402706
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0xc