Function at 0x414a70
Capabilities:
Query environment variable

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x5c
mov eax, dword [esp + 0x74]
mov ebx, dword [esp + 0x70]
mov dword [esp + 0x40], 0
mov ecx, dword [esp + 0x7c]
mov dword [esp + 0x44], 0
mov dword [esp], ebx
mov esi, dword [esp + 0x78]
mov dword [esp + 4], eax
mov dword [esp + 0x38], ecx
mov dword [esp + 0x34], eax
mov dword [esp + 0x48], 0
mov dword [esp + 0x4c], 0
call sym._newWideCString__stdZwidestrs_u316_8
sub esp, 8
mov dword [esp], 0x4331ac
mov dword [esp + 0x2c], eax
mov dword [esp + 0x28], edx
call sym.___emutls_get_address
mov ebp, eax
movzx eax, byte [eax]
test al, al
jne 0x414e18
mov eax, dword [esp + 0x80]
mov edi, esi
test eax, eax
je 0x414c80
test esi, esi
je 0x414cf8
lea ecx, [ebx + esi + 1]
call sym._rawNewString_4
mov dword [esp + 0x30], edx
mov edi, eax
test ebx, ebx
jle 0x414f60
lea ecx, [eax + edx + 4]
mov eax, ebx
add eax, 1
jo 0x414fc0
test eax, eax
js 0x4151d0
mov edx, dword [esp + 0x34]
mov dword [esp], ecx
mov dword [esp + 8], eax
add edx, 4
mov dword [esp + 0x34], ecx
mov dword [esp + 4], edx
call sym._memcpy
add ebx, edi
mov ecx, dword [esp + 0x34]
jo 0x414fc0
mov eax, dword [esp + 0x30]
mov edi, ebx
lea ecx, [ebx + eax + 4]
mov ebx, edi
mov eax, 0x3d
add ebx, 1
mov word [ecx], ax
jo 0x415260
test esi, esi
jle 0x414baa
mov eax, esi
add eax, 1
jo 0x415361
test eax, eax
js 0x415190
mov edi, dword [esp + 0x30]
mov ecx, dword [esp + 0x38]
mov dword [esp + 8], eax
add ecx, 4
lea edx, [ebx + edi + 4]
mov dword [esp + 4], ecx
mov dword [esp], edx
call sym._memcpy
add esi, ebx
jo 0x415361
mov ebx, esi
mov eax, dword [esp + 0x30]
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._newWideCString__stdZwidestrs_u316_8
sub esp, 8
cmp byte [ebp], 0
mov esi, eax
mov ebx, edx
jne 0x414f70
mov dword [esp], edx
call dword [sym.imp.msvcrt.dll__wputenv]
mov edi, eax
test eax, eax
je 0x414ec8
call dword [sym.imp.msvcrt.dll__errno]
mov dword [eax], 0x16
mov dword [esp], esi
mov dword [esp + 4], ebx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x4152d8
mov eax, dword [esp + 0x30]
test eax, eax
je 0x414c1c
mov eax, dword [eax]
mov dword [esp + 0x34], eax
test eax, 0x40000000
je 0x415218
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414c6d
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414c6d
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
add esp, 0x5c
mov edi, 0xffffffff
pop ebx
mov eax, edi
pop esi
pop edi
pop ebp
ret 0x14
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__wgetenv]
test eax, eax
je 0x414af0
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce6
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce6
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
xor edi, edi
add esp, 0x5c
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret 0x14
lea ecx, [ebx + 3]
call sym._rawNewString_4
mov esi, edx
mov edx, eax
mov dword [esp + 0x30], esi
lea ecx, [eax + esi + 4]
test ebx, ebx
jle 0x414d58
mov eax, ebx
add eax, 1
jo 0x4152b8
mov dword [esp + 0x3c], edx
test eax, eax
js 0x415270
mov edx, dword [esp + 0x34]
mov dword [esp], ecx
mov dword [esp + 8], eax
add edx, 4
mov dword [esp + 0x34], ecx
mov dword [esp + 4], edx
call sym._memcpy
mov edx, dword [esp + 0x3c]
mov ecx, dword [esp + 0x34]
add ebx, edx
jo 0x4152b8
lea ecx, [ebx + esi + 4]
mov edx, ebx
mov eax, edx
mov dword [ecx], 0x20203d
add eax, 3
jo 0x4152e8
mov dword [esp], eax
mov dword [esp + 4], esi
call sym._newWideCString__stdZwidestrs_u316_8
sub esp, 8
mov dword [esp + 0x40], eax
movzx eax, byte [ebp]
mov dword [esp + 0x44], edx
test al, al
jne 0x414e22
mov eax, dword [esp + 0x44]
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__wputenv]
mov edi, eax
test eax, eax
je 0x414ff0
call dword [sym.imp.msvcrt.dll__errno]
mov dword [eax], 0x16
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414c6d
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414c6d
test esi, esi
je 0x414c56
test dword [esi], 0x40000000
jne 0x414c56
mov dword [esp], esi
call sym._deallocShared
jmp 0x414c56
mov dword [esp + 0x30], 0
xor edi, edi
mov ecx, dword [esp + 0x48]
mov ebx, dword [esp + 0x4c]
mov byte [ebp], 0
mov byte [esp + 0x34], al
mov dword [esp], ecx
mov dword [esp + 4], ebx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce8
mov ecx, dword [esp + 0x40]
mov ebx, dword [esp + 0x44]
mov dword [esp], ecx
mov dword [esp + 4], ebx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce8
mov esi, dword [esp + 0x30]
movzx eax, byte [esp + 0x34]
test esi, esi
je 0x414e8b
mov esi, dword [esi]
mov dword [esp + 0x34], esi
and esi, 0x40000000
je 0x415230
mov byte [esp + 0x30], al
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce8
movzx eax, byte [esp + 0x30]
mov byte [ebp], al
add esp, 0x5c
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret 0x14
mov dword [esp], esi
mov dword [esp + 4], ebx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414fa4
mov eax, dword [esp + 0x30]
test eax, eax
je 0x414efa
mov eax, dword [eax]
mov dword [esp + 0x34], eax
test eax, 0x40000000
je 0x414fd8
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce8
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce8
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
jmp 0x414ce8
lea ecx, [edi + edx + 4]
jmp 0x414b57
mov byte [ebp], 0
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414fa2
mov eax, dword [esp + 0x30]
test eax, eax
je 0x414fa2
mov eax, dword [eax]
mov dword [esp + 0x34], eax
test eax, 0x40000000
je 0x41524a
xor edi, edi
mov dword [esp + 0x30], 0
mov eax, 1
jmp 0x414e22
mov dword [esp + 0x34], ecx
call sym._raiseOverflow
mov ecx, dword [esp + 0x34]
jmp 0x414b57
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sym._deallocShared
jmp 0x414efa
mov eax, dword [esp + 0x28]
mov ebx, dword [sym.imp.msvcrt.dll__wgetenv]
mov dword [esp], eax
call ebx
xor edx, edx
mov word [eax], dx
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call ebx
mov ecx, 0x3d
mov word [eax + 2], cx
mov eax, dword [sym.imp.msvcrt.dll__environ]
mov ebx, dword [eax]
test ebx, ebx
je 0x4150d8
mov eax, dword [esp + 0x28]
mov dword [esp + 8], 0
mov dword [esp], 0
mov dword [esp + 4], eax
call sym._wcstombs
mov ebx, eax
cmp eax, 0xffffffff
je 0x4150d8
test eax, eax
js 0x415337
add ebx, 1
jo 0x41536b
test ebx, ebx
js 0x4152fa
mov ecx, ebx
call sym._newSeq__stdZprivateZwin95setenv_u42_4
test eax, eax
jle 0x415345
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x3c], eax
lea eax, [edx + 4]
mov dword [esp + 8], ebx
mov ebx, eax
mov dword [esp + 4], ecx
mov dword [esp], eax
mov dword [esp + 0x34], edx
call sym._wcstombs
mov edx, dword [esp + 0x34]
mov ecx, dword [esp + 0x3c]
cmp eax, 0xffffffff
je 0x4150c9
mov dword [esp], ebx
mov dword [esp + 0x3c], edx
mov dword [esp + 0x34], ecx
call sym._getenv
mov byte [eax], 0
mov dword [esp], ebx
call sym._getenv
mov edx, dword [esp + 0x3c]
mov ecx, dword [esp + 0x34]
mov byte [eax + 1], 0x3d
mov dword [esp], ecx
mov dword [esp + 4], edx
call sym._eqdestroy___stdZprivateZwin95setenv_u145_8
sub esp, 8
mov eax, dword [esp + 0x38]
mov dword [esp], 0
mov dword [esp + 4], eax
call sym._newWideCString__stdZwidestrs_u316_8
sub esp, 8
mov dword [esp + 0x48], eax
movzx eax, byte [ebp]
mov dword [esp + 0x4c], edx
test al, al
jne 0x414e22
mov eax, dword [esp + 0x4c]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call dword [0x442118]
sub esp, 8
test eax, eax
je 0x414da3
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce6
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._eqdestroy___stdZwidestrs_u7_8
sub esp, 8
cmp byte [ebp], 0
jne 0x414ce6
test esi, esi
je 0x414ccf
test dword [esi], 0x40000000
jne 0x414ccf
mov dword [esp], esi
call sym._deallocShared
jmp 0x414ccf
mov dword [esp + 0x10], 0x7fffffff
mov dword [esp + 0x14], 0
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp], 0x80000000
mov dword [esp + 4], 0xffffffff
call sym._raiseRangeErrorI
jmp 0x414baa
mov dword [esp + 0x10], 0x7fffffff
mov dword [esp + 0x14], 0
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp], 0x80000000
mov dword [esp + 4], 0xffffffff
mov dword [esp + 0x34], ecx
call sym._raiseRangeErrorI
mov ecx, dword [esp + 0x34]
jmp 0x414b57
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sym._deallocShared
jmp 0x414c1c
mov byte [esp + 0x34], al
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sym._deallocShared
movzx eax, byte [esp + 0x34]
jmp 0x414e8b
mov eax, dword [esp + 0x30]
xor edi, edi
mov dword [esp], eax
call sym._deallocShared
jmp 0x414fa4
call sym._raiseOverflow
mov ebx, edi
jmp 0x414b6a
mov dword [esp + 0x10], 0x7fffffff
mov dword [esp + 0x14], 0
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp], 0x80000000
mov dword [esp + 4], 0xffffffff
mov dword [esp + 0x34], ecx
call sym._raiseRangeErrorI
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
jmp 0x414d58
mov dword [esp + 0x3c], edx
mov dword [esp + 0x34], ecx
call sym._raiseOverflow
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x3c]
jmp 0x414d58
mov edi, 0xffffffff
jmp 0x414fa4
mov dword [esp + 0x34], edx
call sym._raiseOverflow
mov eax, dword [esp + 0x34]
jmp 0x414d69
mov dword [esp + 0x10], 0x7fffffff
mov dword [esp + 0x14], 0
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp], 0x80000000
mov dword [esp + 4], 0xffffffff
call sym._raiseRangeErrorI
movzx eax, byte [ebp]
jmp 0x414e22
call sym._raiseRangeErrorNoArgs
movzx eax, byte [ebp]
jmp 0x414e22
lea eax, [eax - 1]
mov dword [esp], 0
mov dword [esp + 4], eax
call sym._raiseIndexError2
movzx eax, byte [ebp]
jmp 0x414e22
call sym._raiseOverflow
jmp 0x414baa
call sym._raiseOverflow
movzx eax, byte [ebp]
jmp 0x414e22