Function at 0x4a2830
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x7c
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x4a2fd0
mov eax, dword [sym.imp.msvcrt.dll__errno]
mov dword [ebp - 0x4c], eax
call eax
mov eax, dword [eax]
mov dword [esp], 0x61cb80
mov dword [ebp - 0x50], eax
call fcn.004a8f00
test eax, eax
jne 0x4a3004
mov eax, dword [ebp + 8]
mov dword [esp], 0x61cbe0
mov dword [ebp - 0x28], 0
test eax, eax
mov eax, dword [ebp + 8]
cmove eax, dword [str.messages]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x30], eax
call fcn.004a8f00
test eax, eax
jne 0x4a3004
lea eax, [ebp - 0x34]
mov dword [esp + 8], 0x4a1f40
mov dword [esp + 4], 0x74c4f4
mov dword [esp], eax
call fcn.004d1580
mov dword [esp], 0x61cbe0
mov edi, eax
mov dword [ebp - 0x5c], eax
call fcn.004a9430
test eax, eax
jne 0x4a3004
test edi, edi
je 0x4a28ee
mov edx, dword [edi]
mov eax, dword [0x74d9dc]
cmp dword [edx + 8], eax
je 0x4a2e45
mov eax, dword [0x74c4f0]
test eax, eax
je 0x4a2c50
mov eax, dword [0x74d9e0]
test eax, eax
mov dword [ebp - 0x40], eax
je 0x4a2e2a
mov ebx, eax
mov esi, dword [ebp + 8]
jmp 0x4a2922
js 0x4a2e23
mov ebx, dword [ebx]
test ebx, ebx
je 0x4a2e36
lea eax, [ebx + 0xc]
mov dword [esp], esi
mov dword [esp + 4], eax
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x4a2912
mov eax, dword [ebx + 4]
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x44], eax
movzx eax, byte [eax]
cmp al, 0x2f
je 0x4a2a14
cmp al, 0x5c
je 0x4a2a14
or eax, 0x20
movsx eax, al
sub eax, 0x61
cmp eax, 0x19
jbe 0x4a2e77
mov eax, dword [ebp - 0x44]
mov ebx, 0x106
mov dword [esp], eax
call sub.msvcrt.dll_strlen
lea edi, [eax + 1]
mov dword [ebp - 0x3c], edi
mov edi, dword [ebp - 0x4c]
jmp 0x4a2993
call edi
cmp dword [eax], 0x22
jne 0x4a2bea
mov eax, ebx
shr eax, 1
lea ebx, [ebx + eax + 0x20]
mov eax, dword [ebp - 0x3c]
lea eax, [ebx + eax + 0x1e]
shr eax, 4
shl eax, 4
call fcn.004ce940
sub esp, eax
lea esi, [esp + 0x23]
call edi
and esi, 0xfffffff0
mov dword [eax], 0
mov dword [esp + 4], ebx
mov dword [esp], esi
call sub.msvcrt.dll__getcwd
test eax, eax
je 0x4a2980
mov dword [esp + 4], 0
mov dword [esp], esi
call sub.msvcrt.dll_strchr
mov ecx, 0x6679f4
nop
lea esi, [esi]
add ecx, 1
movzx edx, byte [ecx - 1]
add eax, 1
test dl, dl
mov byte [eax - 1], dl
jne 0x4a29e0
mov edx, dword [ebp - 0x44]
jmp 0x4a2a03
add eax, 1
add edx, 1
movzx ecx, byte [edx - 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x4a2a00
mov dword [ebp - 0x44], esi
cmp dword [ebp + 0x1c], 3
je 0x4a2edf
jle 0x4a2c60
cmp dword [ebp + 0x1c], 5
mov ebx, 0x667a21
je 0x4a2a50
mov ebx, 0x667a16
jl 0x4a2a50
cmp dword [ebp + 0x1c], 0x6c1
mov ebx, 0x667a29
jne 0x4a2c8a
nop
lea esi, [esi]
mov eax, dword [ebp + 0x1c]
mov dword [esp + 4], ebx
mov dword [esp], eax
call fcn.004a4c40
test eax, eax
mov edx, eax
mov dword [ebp - 0x3c], 0
je 0x4a2fd7
mov ecx, 2
mov esi, edx
mov edi, 0x667a47
repe cmpsb byte [esi], byte es:[edi]
jne 0x4a2de4
mov eax, dword [ebp + 8]
mov dword [ebp - 0x3c], edx
mov dword [esp], eax
call sub.msvcrt.dll_strlen
mov dword [esp], ebx
mov edi, eax
mov dword [ebp - 0x54], eax
call sub.msvcrt.dll_strlen
lea eax, [edi + eax + 0x23]
shr eax, 4
shl eax, 4
call fcn.004ce940
mov edx, dword [ebp - 0x3c]
sub esp, eax
lea eax, [esp + 0x23]
and eax, 0xfffffff0
mov dword [ebp - 0x48], eax
mov esi, eax
jmp 0x4a2ac3
mov esi, eax
add ebx, 1
movzx ecx, byte [ebx - 1]
lea eax, [esi + 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x4a2ac1
mov ebx, 0x6679f4
jmp 0x4a2ae5
mov esi, eax
add eax, 1
add ebx, 1
movzx ecx, byte [ebx - 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x4a2ae0
mov eax, dword [ebp - 0x54]
mov dword [esp], esi
mov dword [ebp - 0x3c], edx
mov dword [esp + 8], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], eax
call fcn.004d0b40
mov edx, dword [ebp - 0x3c]
mov ecx, 0x667a43
add ecx, 1
movzx ebx, byte [ecx - 1]
add eax, 1
test bl, bl
mov byte [eax - 1], bl
jne 0x4a2b14
mov dword [esp], edx
mov dword [ebp - 0x58], edx
call sub.msvcrt.dll_strlen
add eax, 0x1f
shr eax, 4
shl eax, 4
call fcn.004ce940
mov edx, dword [ebp - 0x58]
sub esp, eax
lea ebx, [esp + 0x23]
and ebx, 0xfffffff0
mov dword [ebp - 0x3c], ebx
mov ebx, edx
nop
movzx eax, byte [ebx]
cmp al, 0x3a
je 0x4a2d24
test al, al
jne 0x4a2c94
mov eax, dword [ebp - 0x3c]
mov byte [eax], 0x43
mov byte [eax + 1], 0
mov esi, dword [ebp - 0x3c]
mov ecx, 2
mov edi, 0x667a47
repe cmpsb byte [esi], byte es:[edi]
je 0x4a2bea
mov esi, dword [ebp - 0x3c]
mov edi, 0x667a52
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
je 0x4a2bea
mov eax, dword [ebp - 0x48]
mov esi, dword [ebp - 0x40]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x3c]
mov dword [esp + 0xc], esi
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x44]
mov dword [esp], eax
call fcn.004a9830
test eax, eax
mov edi, eax
je 0x4a2b50
lea eax, [ebp - 0x38]
mov dword [esp + 0xc], 1
mov dword [esp + 4], esi
mov dword [esp], edi
mov dword [esp + 0x10], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 8], eax
call fcn.004a2010
test eax, eax
je 0x4a2d30
cmp eax, 0xffffffff
mov esi, eax
jne 0x4a2d8b
mov dword [esp], 0x61cb80
call fcn.004a9430
test eax, eax
jne 0x4a3004
cmp dword [0x74c4f0], 1
je 0x4a2c20
mov dword [esp], str.GETTEXT_LOG_UNTRANSLATED
call sub.msvcrt.dll_getenv
test eax, eax
je 0x4a2c20
cmp byte [eax], 0
jne 0x4a2eb6
mov eax, dword [ebp - 0x4c]
call eax
mov edi, dword [ebp - 0x50]
mov dword [eax], edi
mov eax, dword [ebp + 0x14]
test eax, eax
je 0x4a2eab
cmp dword [ebp + 0x18], 1
je 0x4a2eab
mov eax, dword [ebp + 0x10]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [0x74c4f0], 0xffffffff
jmp 0x4a28fb
cmp dword [ebp + 0x1c], 1
mov ebx, 0x6679f6
je 0x4a2a50
mov ebx, 0x667a01
jg 0x4a2a50
mov edi, dword [ebp + 0x1c]
mov ebx, 0x667a35
test edi, edi
je 0x4a2a50
mov ebx, 0x667a3c
jmp 0x4a2a50
mov edx, dword [ebp - 0x3c]
jmp 0x4a2ca4
cmp al, 0x3a
je 0x4a2cb4
add edx, 1
add ebx, 1
mov byte [edx - 1], al
movzx eax, byte [ebx]
test al, al
jne 0x4a2ca0
cmp dword [0x74c4f0], 1
mov byte [edx], 0
jne 0x4a2b6d
mov eax, dword [ebp - 0x3c]
mov dword [esp + 4], 0x2f
mov dword [esp], eax
call sub.msvcrt.dll_strchr
test eax, eax
jne 0x4a2b50
mov eax, dword [ebp - 0x3c]
mov dword [esp + 4], 0x5c
mov dword [esp], eax
call sub.msvcrt.dll_strchr
test eax, eax
jne 0x4a2b50
mov edi, dword [ebp - 0x3c]
movzx eax, byte [edi]
mov byte [ebp - 0x58], al
or eax, 0x20
movsx eax, al
sub eax, 0x61
cmp eax, 0x19
ja 0x4a2b6d
cmp byte [edi + 1], 0x3a
jne 0x4a2b6d
jmp 0x4a2b50
add ebx, 1
jmp 0x4a2b50
mov eax, dword [edi + 0x10]
test eax, eax
je 0x4a2b50
mov dword [ebp - 0x58], ebx
xor esi, esi
mov ebx, dword [ebp - 0x40]
jmp 0x4a2d54
add esi, 1
mov eax, dword [edi + esi*4 + 0x10]
test eax, eax
je 0x4a2ee9
lea ecx, [ebp - 0x38]
mov dword [esp + 0xc], 1
mov dword [esp + 4], ebx
mov dword [esp], eax
mov dword [esp + 0x10], ecx
mov ecx, dword [ebp + 0xc]
mov dword [esp + 8], ecx
call fcn.004a2010
cmp eax, 0xffffffff
je 0x4a2bea
test eax, eax
je 0x4a2d45
mov ecx, esi
mov esi, eax
mov edi, dword [edi + ecx*4 + 0x10]
mov ecx, dword [ebp - 0x5c]
test ecx, ecx
je 0x4a2ef1
mov ecx, dword [ebp - 0x5c]
mov edx, dword [0x74d9dc]
mov eax, dword [ecx]
mov dword [eax + 8], edx
mov dword [eax + 0xc], edi
mov eax, dword [ecx]
mov edx, dword [ebp - 0x38]
mov dword [eax + 0x10], esi
mov eax, dword [ecx]
mov dword [eax + 0x14], edx
mov eax, dword [ebp - 0x4c]
call eax
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x50]
test edx, edx
mov dword [eax], ecx
jne 0x4a2fea
mov dword [esp], 0x61cb80
call fcn.004a9430
test eax, eax
jne 0x4a3004
mov eax, esi
jmp 0x4a2c42
mov dword [esp], str.LANGUAGE
mov dword [ebp - 0x48], edx
call sub.msvcrt.dll_getenv
test eax, eax
mov edx, dword [ebp - 0x48]
je 0x4a2e03
cmp byte [eax], 0
jne 0x4a2e89
mov esi, dword [ebp - 0x3c]
test esi, esi
je 0x4a2a84
mov dword [ebp - 0x3c], edx
call fcn.004a3260
mov edx, dword [ebp - 0x3c]
test eax, eax
cmovne edx, eax
jmp 0x4a2a84
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x44], str._home_dave_mxe.git_usr_i686_w64_mingw32.static_share_locale
jmp 0x4a2a14
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x44], str._home_dave_mxe.git_usr_i686_w64_mingw32.static_share_locale
jmp 0x4a2a14
mov eax, dword [ebp + 0x14]
test eax, eax
jne 0x4a2e90
mov esi, dword [edx + 0x10]
mov dword [esp], 0x61cb80
call fcn.004a9430
test eax, eax
jne 0x4a3004
mov eax, dword [ebp - 0x4c]
call eax
mov edi, dword [ebp - 0x50]
mov dword [eax], edi
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [ebp - 0x44]
cmp byte [eax + 1], 0x3a
jne 0x4a2963
jmp 0x4a2a14
mov edx, eax
jmp 0x4a2a84
mov ecx, dword [edx + 0x10]
mov eax, dword [edx + 0xc]
mov edx, dword [edx + 0x14]
mov eax, dword [eax + 8]
mov dword [esp], edx
mov edx, dword [ebp + 0x18]
call fcn.004a1fb0
mov esi, eax
jmp 0x4a2e4f
mov eax, dword [ebp + 0xc]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov edi, dword [ebp + 0x14]
mov dword [esp], eax
mov dword [esp + 0x10], edi
mov edi, dword [ebp + 0x10]
mov dword [esp + 0xc], edi
mov edi, dword [ebp + 0xc]
mov dword [esp + 8], edi
mov edi, dword [ebp + 8]
mov dword [esp + 4], edi
call fcn.004a4de0
jmp 0x4a2c20
mov ebx, 0x667a0a
jmp 0x4a2a50
mov ebx, dword [ebp - 0x58]
jmp 0x4a2b50
mov eax, dword [ebp + 0xc]
mov dword [esp], eax
call sub.msvcrt.dll_strlen
lea edx, [eax + 1]
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x3c], edx
lea eax, [edx + eax + 0x19]
mov dword [esp], eax
call sub.msvcrt.dll_malloc
test eax, eax
mov ebx, eax
je 0x4a2db4
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 0x3c]
lea eax, [eax + 0x18]
mov dword [esp], eax
mov dword [esp + 4], ecx
mov dword [esp + 8], edx
call fcn.004d0b40
mov edx, eax
mov eax, dword [ebp - 0x54]
mov dword [esp], edx
mov dword [ebp - 0x3c], edx
add eax, 1
mov dword [esp + 8], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], eax
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp + 0x1c]
mov edx, dword [ebp - 0x3c]
mov dword [ebx + 0xc], edi
mov dword [ebx + 0x10], esi
mov dword [ebx + 4], eax
mov eax, dword [0x74d9dc]
mov dword [ebx], edx
mov dword [ebx + 8], eax
mov eax, dword [ebp - 0x38]
mov dword [ebx + 0x14], eax
mov dword [esp], 0x61cbe0
call fcn.004a90a0
test eax, eax
jne 0x4a3004
mov dword [esp + 8], 0x4a1f40
mov dword [esp + 4], 0x74c4f4
mov dword [esp], ebx
call fcn.004d15d0
mov dword [esp], 0x61cbe0
mov dword [ebp - 0x3c], eax
call fcn.004a9430
test eax, eax
jne 0x4a3004
mov edx, dword [ebp - 0x3c]
test edx, edx
je 0x4a2fbf
cmp ebx, dword [edx]
je 0x4a2db4
mov dword [esp], ebx
call fcn.004defc0
jmp 0x4a2db4
xor eax, eax
jmp 0x4a2c42
call fcn.004a4cb0
mov dword [ebp - 0x3c], 1
mov edx, eax
jmp 0x4a2a70
mov edx, dword [ebp - 0x38]
mov eax, dword [edi + 8]
mov ecx, esi
mov dword [esp], edx
mov edx, dword [ebp + 0x18]
call fcn.004a1fb0
mov esi, eax
jmp 0x4a2dc9
call sub.msvcrt.dll_abort
nop
nop
nop
nop
nop
nop
nop