Function at 0x140003800
Capabilities:
Query environment variable

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rdi
push rsi
push rbx
sub rsp, 0x58
lea rbp, [rsp + 0x50]
mov esi, dword [0x14001a340]
mov qword [rbp + 0x50], rcx
cmp esi, 0xffffffff
je 0x1400038d0
dec esi
js 0x140003887
mov rax, qword [rbp + 0x50]
mov r13, qword [0x14001a0a0]
xor r15d, r15d
mov rdi, qword [sym.imp.ucrtbase.dll_strcmp]
lea r12, [rax + 1]
jmp 0x140003859
lea r15d, [rbx + 1]
cmp r15d, esi
jg 0x140003887
lea eax, [rsi + r15]
mov rcx, r12
mov ebx, eax
shr ebx, 0x1f
add ebx, eax
sar ebx, 1
movsxd r14, ebx
shl r14, 4
add r14, r13
lea rdx, [r14 + 1]
call rdi
test eax, eax
je 0x1400038c0
jns 0x140003850
lea esi, [rbx - 1]
cmp r15d, esi
jle 0x140003859
mov rdi, qword [rbp + 0x50]
movzx eax, byte [0x14001a0b0]
cmp byte [rdi], 0
js 0x1400038b0
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
mov rdi, qword [rbp + 0x50]
mov byte [rdi], al
jmp 0x140003897
movzx eax, byte [r14]
jmp 0x140003897
lea rcx, str.WINEDEBUG
call qword [sym.imp.ucrtbase.dll_getenv]
mov dword [0x14001a340], 0
mov rcx, rax
test rax, rax
je 0x140003887
call qword [sym.imp.ucrtbase.dll__strdup]
mov qword [rbp - 8], rax
test rax, rax
je 0x140003a3a
mov r12, qword [rbp - 8]
nop word cs:[rax + rax]
mov edx, 0x2c
mov rcx, r12
xor r13d, r13d
call qword [sym.imp.ucrtbase.dll_strchr]
test rax, rax
je 0x14000392d
mov byte [rax], 0
lea r13, [rax + 1]
lea rdx, [0x14001bc60]
mov rcx, r12
call qword [sym.imp.ucrtbase.dll_strcspn]
lea r15, [r12 + rax]
mov rbx, rax
movzx esi, byte [r15]
test sil, sil
je 0x1400039d8
cmp r15, r12
jbe 0x140003a60
xor edi, edi
lea r14, str.fixme
mov eax, 5
mov qword [rbp - 0x10], r15
cdqe
mov r15, r14
mov r14, rdi
mov edi, r14d
cmp rax, rbx
jne 0x140003992
mov r8, rbx
mov rdx, r15
mov rcx, r12
call sym.memcmp
test eax, eax
je 0x140003bb0
inc r14
cmp r14, 4
je 0x1400039c8
lea rax, str.fixme
mov edi, r14d
mov r15, qword [rax + r14*8]
mov rcx, r15
call qword [sym.imp.ucrtbase.dll_strlen]
cdqe
cmp rax, rbx
je 0x14000397c
inc r14
cmp r14, 4
jne 0x14000399b
nop word [rax + rax]
test r13, r13
je 0x140003a30
mov r12, r13
jmp 0x140003910
movzx esi, byte [r12]
cmp sil, 0x2d
je 0x140003a48
lea ebx, [rsi - 0x2b]
and ebx, 0xfd
je 0x140003b08
mov r14d, 0xffffffff
xor ebx, ebx
test sil, sil
je 0x1400039c8
mov ecx, 4
mov rsi, r12
lea rdi, [0x14001bc63]
repe cmpsb byte [rsi], byte [rdi]
seta al
sbb al, 0
test al, al
jne 0x140003a70
not ebx
and bl, byte [0x14001a0b0]
or r14d, ebx
mov byte [0x14001a0b0], r14b
test r13, r13
jne 0x1400039cd
mov rcx, qword [rbp - 8]
call qword [sym.imp.ucrtbase.dll_free]
mov esi, dword [0x14001a340]
jmp 0x140003828
mov ebx, 0xffffffff
xor r14d, r14d
mov r15, r12
movzx esi, byte [r15 + 1]
lea r12, [r15 + 1]
jmp 0x1400039fa
mov r12, r15
jmp 0x1400039dd
mov rcx, r12
call qword [sym.imp.ucrtbase.dll_strlen]
mov qword [rbp - 0x18], rax
cmp rax, 0xe
ja 0x1400039c8
mov eax, dword [0x14001a340]
mov rcx, qword [0x14001a0a0]
mov dword [rbp - 0x10], eax
dec eax
mov qword [rbp - 0x20], rcx
mov edi, eax
js 0x140003caf
mov rax, qword [sym.imp.ucrtbase.dll_strcmp]
xor r15d, r15d
mov qword [rbp - 0x28], r13
mov byte [rbp - 0x2a], bl
mov r13d, r15d
mov rbx, rcx
mov byte [rbp - 0x29], r14b
mov r15, rax
jmp 0x140003ad1
lea r13d, [r14 + 1]
cmp r13d, edi
jg 0x140003b32
lea eax, [rdi + r13]
mov rcx, r12
mov r8d, eax
shr r8d, 0x1f
add r8d, eax
sar r8d, 1
movsxd rsi, r8d
mov r14, rsi
shl rsi, 4
add rsi, rbx
lea rdx, [rsi + 1]
call r15
test eax, eax
je 0x140003b16
jns 0x140003ac8
lea edi, [r14 - 1]
jmp 0x140003acc
mov r15, r12
mov r14d, 0xffffffff
jmp 0x140003a53
movzx ebx, byte [rbp - 0x2a]
movzx r14d, byte [rbp - 0x29]
mov r13, qword [rbp - 0x28]
not ebx
and bl, byte [rsi]
or r14d, ebx
mov byte [rsi], r14b
jmp 0x1400039c8
movsxd rsi, r13d
movzx r14d, byte [rbp - 0x29]
movzx ebx, byte [rbp - 0x2a]
mov r13, qword [rbp - 0x28]
mov r15, rsi
shl rsi, 4
mov eax, dword [0x14001a350]
cmp dword [rbp - 0x10], eax
jge 0x140003c45
add rsi, qword [rbp - 0x20]
cmp r15d, dword [rbp - 0x10]
jl 0x140003c18
mov rax, qword [rbp - 0x18]
lea rcx, [rsi + 1]
inc rax
cmp eax, 8
jae 0x140003be9
test al, 4
jne 0x140003cc7
test eax, eax
je 0x140003b92
movzx edx, byte [r12]
mov byte [rsi + 1], dl
test al, 2
jne 0x140003cde
mov eax, dword [rbp - 0x10]
not ebx
and bl, byte [0x14001a0b0]
or r14d, ebx
inc eax
mov byte [rsi], r14b
mov dword [0x14001a340], eax
jmp 0x1400039c8
mov r14d, 1
mov ecx, edi
mov r15, qword [rbp - 0x10]
shl r14d, cl
mov ebx, r14d
cmp sil, 0x2b
je 0x140003ca5
sub esi, 0x2b
and esi, 0xfd
mov r14d, esi
je 0x140003a53
mov r12, r15
xor r14d, r14d
jmp 0x1400039ff
mov edx, eax
dec eax
mov r8, qword [r12 + rdx - 8]
mov qword [rcx + rdx - 8], r8
cmp eax, 8
jb 0x140003b92
and eax, 0xfffffff8
xor edx, edx
mov r8d, edx
add edx, 8
mov r9, qword [r12 + r8]
mov qword [rcx + r8], r9
cmp edx, eax
jb 0x140003c01
jmp 0x140003b92
mov r8d, dword [rbp - 0x10]
lea eax, [r15 + 1]
mov rcx, qword [rbp - 0x20]
mov rdx, rsi
cdqe
sub r8d, r15d
shl rax, 4
movsxd r8, r8d
add rcx, rax
shl r8, 4
call qword [sym.imp.ucrtbase.dll_memmove]
jmp 0x140003b66
add eax, eax
mov edx, 0x10
cmp eax, 0x10
cmovl eax, edx
mov dword [0x14001a350], eax
cdqe
shl rax, 4
mov r8, rax
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
cmp qword [rbp - 0x20], 0
mov rcx, qword [rax + 0x30]
je 0x140003cb9
mov r9, r8
xor edx, edx
mov r8, qword [rbp - 0x20]
call qword [sym.imp.kernel32.dll_HeapReAlloc]
mov qword [rbp - 0x20], rax
mov rax, qword [rbp - 0x20]
mov qword [0x14001a0a0], rax
mov eax, dword [0x14001a340]
mov dword [rbp - 0x10], eax
jmp 0x140003b58
mov r12, r15
xor ebx, ebx
jmp 0x140003a50
xor esi, esi
xor r15d, r15d
jmp 0x140003b49
xor edx, edx
call qword [sym.imp.kernel32.dll_HeapAlloc]
mov qword [rbp - 0x20], rax
jmp 0x140003c8c
mov edx, dword [r12]
mov eax, eax
mov dword [rsi + 1], edx
mov edx, dword [r12 + rax - 4]
mov dword [rcx + rax - 4], edx
jmp 0x140003b92
mov eax, eax
movzx edx, word [r12 + rax - 2]
mov word [rcx + rax - 2], dx
jmp 0x140003b92