Function at 0x10016381
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1007d1c9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1e0
movzx eax, byte [ebp + 0x20]
test eax, eax
je 0x10016ea0
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x124], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x100], eax
lea eax, [ebp + 0x18]
mov dword [ebp - 0xf8], eax
lea eax, [ebp + 8]
mov dword [ebp - 0x144], eax
lea eax, [ebp + 0x10]
mov dword [ebp - 0x12c], eax
mov eax, dword [ebp - 0x12c]
movzx eax, byte [eax]
test eax, eax
je 0x10016e8a
mov eax, dword [ebp - 0x144]
mov dword [ebp - 0x110], eax
mov eax, dword [ebp - 0xf8]
mov dword [ebp - 0xcc], eax
mov eax, dword [ebp - 0x124]
mov dword [ebp - 0xd4], eax
mov eax, dword [ebp - 0x100]
mov dword [ebp - 0xf4], eax
mov dword [ebp - 0x10], 0xffffffff
mov dword [ebp - 0xd0], 0x4bf7a832
mov dword [ebp - 0x10], 0xfffffff6
cmp dword [ebp - 0x10], 0
je 0x10016628
mov dword [ebp - 0x98], 0xffffffff
mov dword [ebp - 0x64], 0
jmp 0x10016455
mov eax, dword [ebp - 0x64]
inc eax
mov dword [ebp - 0x64], eax
cmp dword [ebp - 0x64], 2
jge 0x10016468
mov eax, dword [ebp - 0x64]
mov dword [ebp + eax*4 - 0x6c], 0xfffffff7
jmp 0x1001644e
mov dword [ebp - 0x10], 1
jmp 0x10016478
mov eax, dword [ebp - 0x10]
dec eax
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jl 0x10016623
mov dword [ebp - 0x14], 0xffffffff
mov dword [ebp - 0x14], 0
jmp 0x10016499
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 1
jg 0x100164af
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp + eax*4 - 0x6c]
mov dword [ebp + ecx*4 - 0x6c], eax
jmp 0x10016492
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x188], eax
push 4
pop eax
shl eax, 0
cmp dword [ebp + eax - 0x6c], 0
jne 0x10016513
cmp dword [ebp - 0x14], 1
jbe 0x100164d7
mov dword [ebp - 0xa4], 1
jmp 0x100164de
and dword [ebp - 0xa4], 0
mov eax, dword [ebp - 0xa4]
sub eax, 0xe3f9
cmp eax, dword [ebp - 0x14]
je 0x100164f7
mov dword [ebp - 0x80], 1
jmp 0x100164fb
and dword [ebp - 0x80], 0
push 4
pop eax
shl eax, 0
mov eax, dword [ebp + eax - 0x6c]
cmp dword [ebp - 0x80], eax
je 0x10016513
and dword [ebp - 0xec], 0
jmp 0x1001651d
mov dword [ebp - 0xec], 1
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp - 0xec]
jne 0x10016534
mov dword [ebp - 0xb8], 1
jmp 0x1001653b
and dword [ebp - 0xb8], 0
mov eax, dword [ebp - 0xb8]
neg eax
cmp eax, dword [ebp - 0x10]
jle 0x10016554
mov dword [ebp - 0x88], 1
jmp 0x1001655b
and dword [ebp - 0x88], 0
cmp dword [ebp - 0x88], 0xffff
jbe 0x10016573
mov dword [ebp - 0xe0], 1
jmp 0x1001657a
and dword [ebp - 0xe0], 0
push 4
pop eax
shl eax, 0
mov eax, dword [ebp + eax - 0x6c]
add eax, dword [ebp - 0xe0]
cmp eax, 0x9271
jl 0x1001659d
mov dword [ebp - 0x90], 1
jmp 0x100165a4
and dword [ebp - 0x90], 0
mov eax, dword [ebp - 0x14]
cmp dword [ebp - 0x90], eax
je 0x100165bb
mov dword [ebp - 0xc0], 1
jmp 0x100165c2
and dword [ebp - 0xc0], 0
mov eax, dword [ebp - 0xc0]
mov dword [ebp - 0x98], eax
mov eax, dword [ebp - 0x98]
neg eax
je 0x100165ea
cmp dword [ebp - 0x14], 0
je 0x100165ea
mov dword [ebp - 0xd8], 1
jmp 0x100165f1
and dword [ebp - 0xd8], 0
cmp dword [ebp - 0xd8], 0xfffffffd
jle 0x10016606
mov dword [ebp - 0xf0], 1
jmp 0x1001660d
and dword [ebp - 0xf0], 0
push 4
pop eax
imul eax, eax, 0
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp + eax - 0x6c]
mov dword [ebp + ecx*4 - 0x6c], eax
jmp 0x10016471
jmp 0x1001681f
mov dword [ebp - 0x178], 0x3aa9c1c7
mov dword [ebp - 0x174], 0x3aa9c1c7
mov dword [ebp - 0x170], 0x3aa9c1c7
mov dword [ebp - 0x16c], 0x3aa9c1c7
mov dword [ebp - 0xa8], 1
mov dword [ebp - 0x13c], 0x11f0b9f5
mov byte [ebp - 0x16], 0
push 0
push 0x58cb
lea eax, [ebp - 0x16]
push eax
push 0x2897
call fcn.1001b72f
add esp, 0x10
mov dword [ebp - 0x84], 0x740c
mov dword [ebp - 0x10c], 0x10007f28
cmp dword [ebp - 0x84], 0x76e6
jle 0x10016715
and dword [ebp - 0x34], 0
jmp 0x100166ad
mov eax, dword [ebp - 0x34]
inc eax
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0x680a
jge 0x10016715
and dword [ebp - 0x54], 0
jmp 0x100166c3
mov eax, dword [ebp - 0x54]
inc eax
mov dword [ebp - 0x54], eax
cmp dword [ebp - 0x54], 0x35d1
jge 0x10016713
and dword [ebp - 0x3c], 0
jmp 0x100166d9
mov eax, dword [ebp - 0x3c]
inc eax
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0x6b44
jge 0x10016711
mov eax, dword [ebp - 0x34]
imul eax, dword [ebp - 0x54]
and eax, dword [ebp - 0x3c]
cdq
mov dword [ebp - 0x150], eax
mov dword [ebp - 0x14c], edx
push dword [ebp - 0x14c]
push dword [ebp - 0x150]
mov ecx, 0x10082bb8
call fcn.1001d55e
jmp 0x100166d2
jmp 0x100166bc
jmp 0x100166a6
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x1a8], eax
mov eax, 0x860b
test eax, eax
je 0x100167f3
cmp dword [ebp - 0x10], 3
jg 0x10016740
cmp dword [ebp - 0x10], 0
jne 0x10016740
and dword [ebp - 0xa0], 0
jmp 0x1001674a
mov dword [ebp - 0xa0], 1
push 4
pop eax
shl eax, 0
mov eax, dword [ebp + eax - 0x178]
imul eax, dword [ebp - 0xa0]
push 4
pop ecx
imul ecx, ecx, 0
cmp eax, dword [ebp + ecx - 0x178]
jge 0x10016779
mov dword [ebp - 0xc8], 1
jmp 0x10016780
and dword [ebp - 0xc8], 0
mov eax, dword [ebp - 0xc8]
mov dword [ebp - 0xa8], eax
cmp dword [ebp - 0xa8], 0xffffa99f
jle 0x100167a4
mov dword [ebp - 0xe8], 1
jmp 0x100167ab
and dword [ebp - 0xe8], 0
push 4
pop eax
imul eax, eax, 0
mov eax, dword [ebp + eax - 0x178]
cmp dword [ebp - 0xe8], eax
jg 0x100167cc
mov dword [ebp - 0xb0], 1
jmp 0x100167d3
and dword [ebp - 0xb0], 0
mov eax, dword [ebp - 0xb0]
mov dword [ebp - 0xd0], eax
imul eax, dword [ebp - 0xd0], 0
test eax, eax
je 0x100167f3
mov dword [ebp - 0x7c], 1
jmp 0x100167f7
and dword [ebp - 0x7c], 0
mov eax, dword [ebp - 0x7c]
sub eax, dword [ebp - 0x10]
mov dword [ebp - 0x13c], eax
cmp dword [ebp - 0x84], 0x71c7
jge 0x1001681f
mov edx, dword [ebp - 0x10c]
mov ecx, 0x10082bb8
call fcn.100202a3
push 0xa98
push 0x4b30
push 0x4355
push 1
push 0x2e0
push 1
call fcn.10015e6b
add esp, 0x18
xor eax, eax
mov word [ebp - 0x72], ax
lea eax, [ebp - 0x72]
push eax
mov eax, dword [ebp - 0x110]
mov eax, dword [eax]
shr eax, 1
inc eax
push eax
lea ecx, [ebp - 0x138]
call fcn.1001da2b
and dword [ebp - 4], 0
push 3
lea ecx, [ebp - 0x1a4]
call fcn.1001d86d
mov byte [ebp - 4], 1
mov dword [ebp - 0x28], 3
lea eax, [ebp - 0x1a4]
push eax
push 1
push 0x640a
push 1
lea eax, [ebp - 0x1b0]
push eax
push 0x4ee2
push 0x4c4e
call fcn.10015532
add esp, 0x1c
mov dword [ebp - 0x28], 2
jmp 0x100168b5
mov eax, dword [ebp - 0x28]
dec eax
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jl 0x100168d3
push 0x5046
push 1
push 0x76bb
push 1
call fcn.10016239
add esp, 0x10
jmp 0x100168ae
push 0x82c
push 0x3888
push 0x2ff4
push 1
push 0
push 0x2537
push 0x2ddc
call fcn.10017d3b
add esp, 0x1c
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x1a4]
call fcn.1001d8ef
and dword [ebp - 0x38], 0
and dword [ebp - 0x44], 0
lea ecx, [ebp - 0x138]
call fcn.1001db98
dec eax
mov dword [ebp - 0x160], eax
jmp 0x1001692a
mov eax, dword [ebp - 0x44]
inc eax
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x44]
cmp eax, dword [ebp - 0x160]
jae 0x10016c71
push dword [ebp - 0x44]
lea ecx, [ebp - 0x138]
call fcn.1001dba0
mov dword [ebp - 0x128], eax
mov dword [ebp - 0xdc], 0x2014
mov dword [ebp - 0x148], 0x10007f84
cmp dword [ebp - 0xdc], 0x21f4
jle 0x100169fe
and dword [ebp - 0x5c], 0
jmp 0x1001697e
mov eax, dword [ebp - 0x5c]
inc eax
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0x4447
jge 0x100169f2
and dword [ebp - 0x4c], 0
jmp 0x10016994
mov eax, dword [ebp - 0x4c]
inc eax
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0x31da
jge 0x100169f0
mov eax, dword [ebp - 0x5c]
mov ecx, dword [ebp - 0x4c]
sar eax, cl
cdq
mov dword [ebp - 0x15c], eax
mov dword [ebp - 0x158], edx
push dword [ebp - 0x158]
push dword [ebp - 0x15c]
lea ecx, [ebp - 0x1d4]
call fcn.1001072e
pop ecx
pop ecx
mov dword [ebp - 0x118], eax
mov ecx, dword [ebp - 0x118]
call fcn.1001d53e
push eax
call fcn.10067b63
pop ecx
lea ecx, [ebp - 0x1d4]
call fcn.1001d534
jmp 0x1001698d
jmp 0x10016977
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
and dword [ebp - 0x40], 0
jmp 0x10016a12
mov eax, dword [ebp - 0x40]
inc eax
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x38]
inc eax
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x40], 2
jae 0x10016c54
mov dword [ebp - 0x1c], 0xfffffff9
mov dword [ebp - 0xac], 0x7d926128
mov dword [ebp - 0x154], 0xea4d59ff
mov dword [ebp - 0x2c], 0
jmp 0x10016a47
mov eax, dword [ebp - 0x2c]
inc eax
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 3
jge 0x10016a5d
mov eax, dword [ebp - 0x2c]
mov dword [ebp + eax*4 - 0x184], 0xd97a888a
jmp 0x10016a40
cmp dword [ebp - 0x1c], 0
je 0x10016a92
mov dword [ebp - 0x140], 0xffffffff
push 0x5cab
push 0
push 0x3c45
lea eax, [ebp - 0x140]
push eax
push 0x96e
call fcn.1001d15f
add esp, 0x14
jmp 0x10016c08
mov dword [ebp - 0x9c], 1
mov dword [ebp - 0x1c], 0
jmp 0x10016aac
mov eax, dword [ebp - 0x1c]
inc eax
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 2
jg 0x10016c08
mov dword [ebp - 0x70], 4
mov dword [ebp - 0x30], 0
jmp 0x10016acd
mov eax, dword [ebp - 0x30]
inc eax
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 3
jge 0x10016ae3
mov eax, dword [ebp - 0x30]
mov dword [ebp + eax*4 - 0x1bc], 1
jmp 0x10016ac6
cmp dword [ebp - 0x9c], 0
je 0x10016afe
cmp dword [ebp - 0x1c], 0
je 0x10016afe
mov dword [ebp - 0x8c], 1
jmp 0x10016b05
and dword [ebp - 0x8c], 0
mov eax, dword [ebp - 0x70]
cmp eax, dword [ebp - 0x8c]
je 0x10016b1c
mov dword [ebp - 0x94], 1
jmp 0x10016b23
and dword [ebp - 0x94], 0
mov eax, dword [ebp - 0x70]
cmp eax, dword [ebp - 0x94]
jg 0x10016b3a
mov dword [ebp - 0x120], 1
jmp 0x10016b41
and dword [ebp - 0x120], 0
push 4
pop eax
imul eax, eax, 0
mov eax, dword [ebp + eax - 0x184]
mov dword [ebp - 0x1ac], eax
cmp dword [ebp - 0x9c], 0
jne 0x10016b6a
push 3
pop eax
test eax, eax
jne 0x10016b6a
and dword [ebp - 0x78], 0
jmp 0x10016b71
mov dword [ebp - 0x78], 1
mov eax, dword [ebp - 0x78]
mov dword [ebp - 0xac], eax
cmp dword [ebp - 0xac], 0
jne 0x10016b8f
mov dword [ebp - 0xb4], 1
jmp 0x10016b96
and dword [ebp - 0xb4], 0
push 4
pop eax
shl eax, 1
mov eax, dword [ebp + eax - 0x1bc]
cmp dword [ebp - 0xb4], eax
jge 0x10016bbc
cmp dword [ebp - 0x70], 0
je 0x10016bbc
mov dword [ebp - 0xbc], 1
jmp 0x10016bc3
and dword [ebp - 0xbc], 0
push 4
pop eax
imul eax, eax, 0
mov eax, dword [ebp + eax - 0x184]
cmp eax, dword [ebp - 0xbc]
jl 0x10016be4
mov dword [ebp - 0xc4], 1
jmp 0x10016beb
and dword [ebp - 0xc4], 0
push 4
pop eax
shl eax, 1
mov eax, dword [ebp + eax - 0x184]
sub eax, dword [ebp - 0xc4]
mov dword [ebp - 0x154], eax
jmp 0x10016aa5
mov eax, dword [ebp - 0xcc]
mov eax, dword [eax]
add eax, dword [ebp - 0x38]
xor edx, edx
div dword [0x100825d8]
mov eax, dword [ebp - 0xd4]
mov eax, dword [eax + 4]
movzx edx, byte [eax + edx]
mov eax, dword [ebp - 0xcc]
mov eax, dword [eax]
add eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0xd4]
mov ecx, dword [ecx]
movzx ecx, byte [ecx + eax]
call fcn.10010766
mov ecx, dword [ebp - 0x128]
add ecx, dword [ebp - 0x40]
mov byte [ecx], al
jmp 0x10016a04
cmp dword [ebp - 0xdc], 0x1e67
jge 0x10016c6c
push dword [ebp - 0x148]
call fcn.10067b63
pop ecx
jmp 0x10016923
mov dword [ebp - 0x24], 0x29a3df60
mov dword [ebp - 0x198], 0x1449c9fb
push 3
lea ecx, [ebp - 0x194]
call fcn.1001d86d
mov byte [ebp - 4], 2
mov dword [ebp - 0x20], 0
jmp 0x10016ca3
mov eax, dword [ebp - 0x20]
inc eax
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 1
jge 0x10016cb9
mov eax, dword [ebp - 0x20]
mov dword [ebp + eax*4 - 0x11c], 0xf1124f01
jmp 0x10016c9c
mov dword [ebp - 0xe4], 0x626
mov dword [ebp - 0x104], 0x10007fbc
cmp dword [ebp - 0xe4], 0x690
jle 0x10016d8d
push 0
push 0
push 0
push 0
call dword [sym.imp.GDI32.dll_CreateICA]
and dword [ebp - 0x58], 0
jmp 0x10016cf8
mov eax, dword [ebp - 0x58]
inc eax
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0x75c
jge 0x10016d8d
and dword [ebp - 0x48], 0
jmp 0x10016d12
mov eax, dword [ebp - 0x48]
inc eax
mov dword [ebp - 0x48], eax
cmp dword [ebp - 0x48], 0x12ea
jge 0x10016d88
and dword [ebp - 0x50], 0
jmp 0x10016d28
mov eax, dword [ebp - 0x50]
inc eax
mov dword [ebp - 0x50], eax
cmp dword [ebp - 0x50], 0x16d2
jge 0x10016d86
mov eax, dword [ebp - 0x48]
imul eax, dword [ebp - 0x50]
and eax, dword [ebp - 0x58]
cdq
mov dword [ebp - 0x168], eax
mov dword [ebp - 0x164], edx
push dword [ebp - 0x164]
push dword [ebp - 0x168]
lea ecx, [ebp - 0x1ec]
call fcn.1001072e
pop ecx
pop ecx
mov dword [ebp - 0x108], eax
mov ecx, dword [ebp - 0x108]
call fcn.1001d53e
push eax
call fcn.10067b63
pop ecx
lea ecx, [ebp - 0x1ec]
call fcn.1001d534
jmp 0x10016d21
jmp 0x10016d0b
jmp 0x10016cf1
lea eax, [ebp - 0x20]
push eax
push 0x3611
push 0x792a
push 0x4319
lea eax, [ebp - 0x194]
push eax
push 1
push 1
push 0x3c3a
push 0x423a
call fcn.10015fb8
add esp, 0x24
cmp dword [ebp - 0xe4], 0x5dd
jge 0x10016dd5
push dword [ebp - 0x104]
call fcn.10067b63
pop ecx
mov dword [ebp - 0x24], 0
jmp 0x10016de5
mov eax, dword [ebp - 0x24]
inc eax
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jg 0x10016e47
mov dword [ebp - 0x60], 0xffffffff
mov dword [ebp - 0x114], 1
mov dword [ebp - 0x60], 0
jmp 0x10016e0c
mov eax, dword [ebp - 0x60]
inc eax
mov dword [ebp - 0x60], eax
cmp dword [ebp - 0x60], 0
jg 0x10016e45
push 1
push 1
push 0x5443
lea eax, [ebp - 0x114]
push eax
push 0x5227
push 0x1d9e
call fcn.10015dbf
add esp, 0x18
mov eax, dword [ebp - 0x24]
cmp dword [ebp + eax*4 - 0x11c], 0
je 0x10016e43
jmp 0x10016e05
jmp 0x10016e05
jmp 0x10016dde
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x194]
call fcn.1001d8ef
lea eax, [ebp - 0x138]
push eax
mov ecx, dword [ebp - 0xf4]
call fcn.1001dacf
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x138]
call fcn.1001daca
jmp 0x10016ebe
mov byte [ebp - 0x15], 0
movzx eax, byte [ebp - 0x15]
test eax, eax
je 0x10016e9e
push 0
call dword [sym.imp.GDI32.dll_CreateHalftonePalette]
jmp 0x10016ebe
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0xfc], eax
push dword [ebp - 0xfc]
push 0x54a0
push 0
call fcn.10012e57
add esp, 0xc
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret