Function at 0x30c1a4
Capabilities:
Query environment variable

Disassembly:
push edi
push esi
push ebp
push ebx
sub esp, 8
mov eax, dword [esp + 0x20]
mov edi, dword [eax]
mov ebx, dword [esp + 0x28]
mov ebp, dword [esp + 0x38]
cmp edi, dword [esp + 0x34]
ja 0x30c38f
mov esi, dword [ebx]
cmp esi, ebp
ja 0x30c38f
test edi, edi
jbe 0x30c20a
mov eax, dword [esp + 0x1c]
movsx edx, byte [eax + edi - 1]
push edx
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
je 0x30c3ca
mov esi, dword [esp + 0x1c]
add edi, 0xffffffff
je 0x30c208
movsx eax, byte [esi + edi - 1]
push eax
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
jne 0x30c1ee
mov esi, dword [ebx]
jmp 0x30c20a
mov esi, dword [ebx]
test esi, esi
jne 0x30c299
mov esi, ebp
xor eax, eax
mov dword [esp], eax
test ebp, ebp
jbe 0x30c261
mov eax, dword [esp + 0x24]
movsx edx, byte [eax]
push edx
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
je 0x30c261
mov ebx, dword [esp]
mov dword [esp + 4], edi
mov edi, dword [esp + 0x24]
add ebx, 1
add esi, 0xffffffff
cmp ebx, ebp
jae 0x30c25a
movsx eax, byte [ebx + edi]
push eax
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
jne 0x30c23b
jmp 0x30c3d1
mov edi, dword [esp + 4]
mov dword [esp], ebx
test esi, esi
jbe 0x30c2d2
mov eax, dword [esp + 0x24]
movsx edx, byte [ebp + eax - 1]
push edx
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
je 0x30c2d2
mov ebx, dword [esp + 0x24]
add ebp, 0xffffffff
add esi, 0xffffffff
je 0x30c2d2
movsx eax, byte [ebp + ebx - 1]
push eax
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
jne 0x30c27e
jmp 0x30c2d2
mov eax, 0
mov dword [esp], eax
jbe 0x30c2d2
mov eax, dword [esp + 0x24]
movsx edx, byte [esi + eax - 1]
push edx
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
je 0x30c2d2
mov ebx, dword [esp + 0x24]
add esi, 0xffffffff
je 0x30c2d2
movsx eax, byte [esi + ebx - 1]
push eax
call dword [sym.imp.MSVCRT.dll_isspace]
pop ecx
test eax, eax
jne 0x30c2bc
lea eax, [edi + esi + 2]
push eax
call dword [sym.imp.MSVCRT.dll_malloc]
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x30c3b4
push edi
mov edx, dword [esp + 0x20]
push edx
push ebp
call fcn.00312070
push ebp
lea ebx, [edi + ebp]
mov byte [ebx], 0
call dword [sym.imp.MSVCRT.dll_getenv]
add esp, 0x10
test eax, eax
je 0x30c3ad
mov edx, 1
test edx, edx
je 0x30c33a
mov edx, dword [esp + 0x2c]
mov ecx, dword [edx]
test ecx, ecx
jne 0x30c33a
mov edx, dword [esp + 0x30]
mov dword [edx], 0
push ebp
call dword [sym.imp.MSVCRT.dll_free]
add esp, 0xc
pop ebx
pop ebp
pop esi
pop edi
ret
mov edx, dword [esp]
add edx, dword [esp + 0x24]
push esi
add ebx, 1
mov byte [ebp + edi], 0x3d
push edx
push ebx
call fcn.00312070
push ebp
add esi, edi
mov byte [ebp + esi + 1], 0
call dword [sym.imp.MSVCRT.dll__putenv]
add esp, 0x10
test eax, eax
jne 0x30c372
mov edx, dword [esp + 0x30]
mov dword [edx], 0
jmp 0x30c380
call dword [sym.imp.MSVCRT.dll__errno]
mov ecx, dword [esp + 0x30]
mov edx, dword [eax]
mov dword [ecx], edx
push ebp
call dword [sym.imp.MSVCRT.dll_free]
add esp, 0xc
pop ebx
pop ebp
pop esi
pop edi
ret
mov eax, dword [esp + 0x30]
mov dword [eax], 0x16
call dword [sym.imp.MSVCRT.dll__errno]
mov dword [eax], 0x16
add esp, 8
pop ebx
pop ebp
pop esi
pop edi
ret
xor edx, edx
jmp 0x30c313
call dword [sym.imp.MSVCRT.dll__errno]
mov edx, dword [esp + 0x30]
mov eax, dword [eax]
mov dword [edx], eax
add esp, 8
pop ebx
pop ebp
pop esi
pop edi
ret
mov esi, dword [ebx]
jmp 0x30c20a
mov edi, dword [esp + 4]
mov dword [esp], ebx
jmp 0x30c261