Function at 0x402fb0
Capabilities:
Query environment variable

Disassembly:
push 0xffffffffffffffff
push 0x4041c7
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x220
mov al, byte [0x40729c]
push ebx
push ebp
push esi
mov ebp, ecx
push edi
mov byte [esp + 0x3c], al
mov ecx, 0x7c
xor eax, eax
lea edi, [esp + 0x3d]
rep stosd dword es:[edi], eax
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
lea ecx, [esp + 0x3c]
stosw word es:[edi], ax
push 0xff
push ecx
push str.systemdrive
stosb byte es:[edi], al
call esi
lea edx, [esp + 0x3c]
lea ecx, [esp + 0x10]
push edx
call sub.MFC42.DLL_CString::CString_1
mov eax, dword [esp + 0x10]
mov dword [esp + 0x238], 0
mov ecx, dword [eax - 8]
mov al, byte [ecx + eax - 1]
cmp al, 0x5c
je 0x403060
lea eax, [esp + 0x10]
push 0x407188
lea ecx, [esp + 0x18]
push eax
push ecx
call sub.MFC42.DLL_operator
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x23c], 1
call fcn.00403642
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 0
call fcn.0040363c
lea edx, [esp + 0x10]
lea ecx, [ebp + 0x68]
push edx
call fcn.00403642
lea eax, [esp + 0x3c]
push 0xff
push eax
push str.windir
call esi
lea ecx, [esp + 0x3c]
push ecx
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::operator_1
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 8]
mov al, byte [ecx + eax - 1]
cmp al, 0x5c
je 0x4030d2
lea edx, [esp + 0x10]
push 0x407188
lea eax, [esp + 0x18]
push edx
push eax
call sub.MFC42.DLL_operator
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x23c], 2
call fcn.00403642
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 0
call fcn.0040363c
lea ecx, [esp + 0x10]
push ecx
lea ecx, [ebp + 0x6c]
call fcn.00403642
lea edx, [esp + 0x3c]
push 0xff
push edx
push str.userprofile
call esi
lea eax, [esp + 0x3c]
lea ecx, [esp + 0x10]
push eax
call sub.MFC42.DLL_CString::operator_1
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 8]
cmp byte [ecx + eax - 1], 0x5c
je 0x403143
lea ecx, [esp + 0x10]
push 0x407188
lea edx, [esp + 0x18]
push ecx
push edx
call sub.MFC42.DLL_operator
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x23c], 3
call fcn.00403642
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 0
call fcn.0040363c
lea eax, [esp + 0x10]
lea ecx, [ebp + 0x70]
push eax
call fcn.00403642
lea ecx, [esp + 0x20]
xor esi, esi
call sub.MFC42.DLL_CFileFind::CFileFind
mov edi, 0x41
mov byte [esp + 0x238], 4
mov dword [esp + 0x18], edi
mov dword [esp + 0x14], 0x19
push edi
lea ecx, [esp + 0x14]
push str._c:.
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x1c]
add esp, 0xc
lea ecx, [esp + 0x20]
push 0
push edx
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
je 0x40324b
push edi
lea eax, [esp + 0x14]
push str._c:_
push eax
call sub.MFC42.DLL_CString::Format
mov edi, dword [ebp + 0x68]
add esp, 0xc
lea ecx, [esp + 0x1c]
mov eax, dword [edi - 8]
push eax
push ecx
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::Left
mov eax, dword [eax]
push edi
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
lea ecx, [esp + 0x1c]
test eax, eax
setne bl
call fcn.0040363c
push 0
push 0
test bl, bl
push 0
lea edi, [ebp + 0x1a4]
push 0
je 0x403219
push 0x407020
push esi
push 1
mov ecx, edi
call sub.MFC42.DLL_CListCtrl::InsertItem
mov edx, dword [esp + 0x10]
mov ecx, edi
push edx
push 1
push esi
call sub.MFC42.DLL_CListCtrl::SetItemText
push 0x40707c
jmp 0x40323c
push 0x40709c
push esi
push 1
mov ecx, edi
call sub.MFC42.DLL_CListCtrl::InsertItem
mov eax, dword [esp + 0x10]
mov ecx, edi
push eax
push 1
push esi
call sub.MFC42.DLL_CListCtrl::SetItemText
push 0x407088
push 2
push esi
mov ecx, edi
call sub.MFC42.DLL_CListCtrl::SetItemText
mov edi, dword [esp + 0x18]
inc esi
mov eax, dword [esp + 0x14]
inc edi
dec eax
mov dword [esp + 0x18], edi
mov dword [esp + 0x14], eax
jne 0x403174
lea ecx, [esp + 0x20]
mov byte [esp + 0x238], 0
call fcn.0040386a
lea ecx, [esp + 0x10]
mov dword [esp + 0x238], 0xffffffff
call fcn.0040363c
mov ecx, dword [esp + 0x230]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x22c
ret