Function at 0x4061a0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
push eax
mov eax, 0x4144
call fcn.004246d8
sub esp, eax
mov eax, dword [esp + eax]
mov esi, dword [eax]
mov ebx, dword [esi]
test ebx, ebx
je 0x406201
movzx eax, byte [0x425010]
mov ebx, dword [esi + 8]
and eax, 8
test al, al
je 0x4061f7
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], str.Peeked_number__d_n
mov dword [esp + 8], str.WCMD_peeknumber
mov dword [esp + 4], 0x425010
mov dword [esp], 3
call sym._wine_dbg_log.constprop.6
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
lea edi, [ebp - 0x400c]
mov dword [esp + 8], 0x2000
mov dword [esp + 4], edi
mov eax, dword [esi + 4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableW]
sub esp, 0xc
test eax, eax
jne 0x4062f0
test byte [0x425010], 8
je 0x4061f7
mov esi, dword [esi + 4]
test esi, esi
je 0x406470
mov eax, esi
shr eax, 0x10
je 0x406310
mov dword [esp + 4], 0xffffffff
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edi, eax
sub esp, 8
mov eax, 0x427175
test edi, edi
jne 0x406323
cmp word [esi], 0
je 0x40627c
add edi, 1
cmp word [esi + edi*2], 0
jne 0x406272
mov eax, 0x224c
mov dword [ebp - 0x413c], ebx
lea edx, [ebp - 0x4136]
mov word [ebp - 0x4138], ax
lea eax, [ebp - 0x4016]
lea ecx, [edi - 1]
cmp edx, eax
ja 0x406423
test edi, edi
jle 0x406423
add esi, 2
movzx eax, word [esi - 2]
cmp ax, 0xd
je 0x406380
ja 0x406360
cmp ax, 9
je 0x406410
cmp ax, 0xa
jne 0x4063b0
mov eax, 0x6e5c
add edx, 2
mov edi, ecx
mov word [edx - 2], ax
jmp 0x406294
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll_wcstol]
mov ebx, eax
jmp 0x40622a
movzx esi, si
mov dword [esp], 0x427168
mov dword [esp + 4], esi
call sym._wine_dbg_sprintf.constprop.9
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Envvar__s_converted_to__d_n
mov dword [esp + 8], str.WCMD_peeknumber
mov dword [esp + 4], 0x425010
mov dword [esp], 3
call sym._wine_dbg_log.constprop.6
movzx eax, byte [0x425010]
and eax, 8
jmp 0x4061cb
cmp ax, 0x22
je 0x406393
cmp ax, 0x5c
jne 0x4063b0
mov ebx, 0x5c5c
add edx, 2
mov edi, ecx
mov word [edx - 2], bx
jmp 0x406294
mov eax, 0x725c
add edx, 2
mov edi, ecx
mov word [edx - 2], ax
jmp 0x406294
mov edi, 0x225c
add edx, 2
mov word [edx - 2], di
mov edi, ecx
jmp 0x406294
lea edi, [eax - 0x20]
cmp di, 0x5e
jbe 0x406460
mov edi, eax
mov byte [edx], 0x5c
add edx, 5
shr di, 0xc
movzx edi, di
movzx ebx, byte [edi + str.0123456789abcdefWCMD_choice]
mov edi, eax
shr di, 8
and edi, 0xf
mov byte [edx - 4], bl
movzx ebx, byte [edi + str.0123456789abcdefWCMD_choice]
mov edi, eax
and eax, 0xf
shr di, 4
movzx eax, byte [eax + str.0123456789abcdefWCMD_choice]
and edi, 0xf
mov byte [edx - 3], bl
movzx ebx, byte [edi + str.0123456789abcdefWCMD_choice]
mov byte [edx - 1], al
mov edi, ecx
mov byte [edx - 2], bl
jmp 0x406294
mov eax, 0x745c
add edx, 2
mov edi, ecx
mov word [edx - 2], ax
jmp 0x406294
mov ebx, dword [ebp - 0x413c]
mov byte [edx], 0x22
lea eax, [edx + 1]
test ecx, ecx
jle 0x406443
mov ecx, 0x2e2e
mov byte [edx + 3], 0x2e
lea eax, [edx + 4]
mov word [edx + 1], cx
mov byte [eax], 0
lea eax, [ebp - 0x4138]
mov dword [esp], eax
call dbg.__wine_dbg_strdup
jmp 0x406323
mov byte [edx], al
mov edi, ecx
add edx, 1
jmp 0x406294
mov eax, 0x42716e
jmp 0x406323