Function at 0x416880
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x9c
mov edx, dword [ebp + 8]
mov eax, dword [edx]
mov edx, 0x16
mov dword [ebp - 0x8c], edx
mov esi, dword [eax + 0xc4c]
mov dword [eax + 0x64], 2
mov edi, dword [eax + 0x39c]
test esi, esi
je 0x41690c
xor esi, esi
lea esi, [esi]
lea edi, [edi]
mov ecx, dword [ebp + 0xc]
mov ebx, dword [ecx + esi*4 + 0x444]
test ebx, ebx
jne 0x4168dc
mov eax, dword [esi*4 + 0x425ae4]
mov dword [ecx + esi*4 + 0x444], eax
mov eax, dword [ebp + 0xc]
mov edx, dword [eax + esi*4 + 0x460]
test edx, edx
jne 0x4168fb
mov eax, dword [esi*4 + 0x425aa0]
mov edx, dword [ebp + 0xc]
mov dword [edx + esi*4 + 0x460], eax
inc esi
cmp esi, 6
jle 0x4168c0
add esp, 0x9c
pop ebx
pop esi
pop edi
pop ebp
ret
test edi, edi
je 0x4169db
mov dword [esp], 0
call sub.cygwin1.dll_nl_langinfo
mov ebx, eax
test ebx, ebx
je 0x41692f
cmp byte [ebx], 0
jne 0x416b63
mov dword [esp], edi
mov eax, 0x2e
mov dword [esp + 4], eax
call sub.cygwin1.dll_strchr
test eax, eax
mov esi, eax
je 0x416b83
mov eax, 0x64
lea edx, [ebp - 0x88]
mov dword [esp + 8], eax
lea eax, [esi + 1]
mov dword [esp], edx
mov dword [esp + 4], eax
call sub.cygwin1.dll_strncpy
mov eax, 0x40
lea ecx, [ebp - 0x88]
mov dword [esp + 4], eax
mov dword [esp], ecx
call sub.cygwin1.dll_strchr
test eax, eax
je 0x416986
mov byte [eax], 0
mov byte [ebp - 0x25], 0
lea ebx, [ebp - 0x88]
mov esi, ebx
movzx ecx, byte [ebx]
cmp cl, 0x5f
sete al
cmp cl, 0x2d
sete dl
or eax, edx
test al, 1
je 0x4169c6
mov esi, esi
lea edi, [edi]
inc ebx
movzx ecx, byte [ebx]
cmp cl, 0x5f
sete al
cmp cl, 0x2d
sete dl
or eax, edx
test al, 1
jne 0x4169b0
test cl, cl
je 0x416a03
movsx eax, cl
inc ebx
mov dword [esp], eax
call sub.cygwin1.dll_toupper
mov byte [esi], al
inc esi
jmp 0x4169b1
mov dword [esp], str.LC_ALL
call sub.cygwin1.dll_getenv
xor ebx, ebx
test eax, eax
mov edi, eax
je 0x416c25
mov ecx, dword [ebp + 8]
mov eax, dword [ecx]
mov dword [eax + 0x39c], edi
jmp 0x416922
mov byte [esi], 0
mov eax, dword [str.EUCJP]
xor esi, esi
test eax, eax
je 0x416a37
mov dword [esp + 4], eax
lea edx, [ebp - 0x88]
mov dword [esp], edx
call sub.cygwin1.dll_strcmp
test eax, eax
je 0x416bf8
inc esi
mov eax, dword [esi*8 + 0x426a20]
test eax, eax
jne 0x416a11
mov eax, dword [str.ja_JP.EUC]
xor esi, esi
test eax, eax
je 0x416a70
mov ebx, eax
mov dword [esp], ebx
call sub.cygwin1.dll_strlen
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], edi
call sub.cygwin1.dll_strncmp
test eax, eax
je 0x416c13
inc esi
mov ebx, dword [esi*8 + 0x426840]
test ebx, ebx
jne 0x416a44
xor esi, esi
cmp dword [0x4265c0], 0x16
je 0x416a9f
xor eax, eax
lea esi, [esi]
mov ecx, dword [ebp - 0x8c]
cmp dword [eax + 0x4265c0], ecx
je 0x416b92
add eax, 0x40
inc esi
cmp dword [eax + 0x4265c0], 0x16
jne 0x416a80
mov ebx, str.noenc
xor edi, edi
mov dword [esp + 4], ebx
mov eax, dword [ebp + 8]
mov dword [esp], eax
call fcn.004089d0
mov eax, dword [ebp - 0x8c]
sub eax, 5
cmp eax, 0xe
ja 0x416ad9
mov edi, dword [ebp - 0x8c]
sub edi, 4
cmp edi, 0x1869f
jle 0x416ad9
mov edi, 0x1869f
xor esi, esi
jmp 0x416b14
mov eax, dword [esi*4 + 0x425ae4]
mov dword [edx + esi*4 + 0x444], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + esi*4 + 0x460]
test eax, eax
jne 0x416b0a
mov eax, dword [esi*4 + 0x425aa0]
mov edx, dword [ebp + 0xc]
mov dword [edx + esi*4 + 0x460], eax
inc esi
cmp esi, 6
jg 0x416901
mov edx, dword [ebp + 0xc]
mov ecx, dword [edx + esi*4 + 0x444]
test ecx, ecx
jne 0x416aeb
test edi, edi
je 0x416add
mov ebx, dword [esi*4 + 0x425cb0]
mov dword [esp], ebx
call sub.cygwin1.dll_strlen
add eax, 4
mov dword [esp], eax
call fcn.00405830
mov ecx, dword [ebp + 0xc]
mov dword [ecx + esi*4 + 0x444], eax
mov dword [esp + 8], edi
mov dword [esp + 4], ebx
mov eax, dword [ecx + esi*4 + 0x444]
mov dword [esp], eax
call sub.cygwin1.dll_sprintf
jmp 0x416aeb
mov dword [esp + 4], ebx
mov eax, 0x64
mov dword [esp + 8], eax
lea eax, [ebp - 0x88]
mov dword [esp], eax
call sub.cygwin1.dll_strncpy
jmp 0x416986
mov dword [esp + 4], edi
mov eax, 0x64
mov dword [esp + 8], eax
jmp 0x416b70
mov eax, dword [eax + 0x4265c4]
shl esi, 6
xor edi, edi
mov dword [esp + 4], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call fcn.004089d0
lea edx, [esi + 0x4265e4]
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx + edi*4 + 0x444]
test eax, eax
jne 0x416bca
mov eax, dword [edx - 0x1c]
mov dword [ecx + edi*4 + 0x444], eax
mov eax, dword [ebp + 0xc]
mov esi, dword [eax + edi*4 + 0x460]
test esi, esi
jne 0x416be4
mov eax, dword [edx]
mov ecx, dword [ebp + 0xc]
mov dword [ecx + edi*4 + 0x460], eax
inc edi
add edx, 4
cmp edi, 6
jle 0x416bb2
add esp, 0x9c
pop ebx
pop esi
pop edi
pop ebp
ret
mov esi, dword [esi*8 + 0x426a24]
cmp esi, 0x16
mov dword [ebp - 0x8c], esi
jne 0x416a70
jmp 0x416a37
mov esi, dword [esi*8 + 0x426844]
mov dword [ebp - 0x8c], esi
jmp 0x416a70
mov dword [esp], str.LC_CTYPE
call sub.cygwin1.dll_getenv
test eax, eax
mov edi, eax
jne 0x4169f3
mov dword [esp], str.LANG
call sub.cygwin1.dll_getenv
test eax, eax
mov edi, eax
jne 0x4169f3
mov edi, 0x426b1d
jmp 0x4169f3