Function at 0x61c897a0
Capabilities:
Query environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
mov r13, rcx
mov r12, rdx
mov rdi, r8
mov esi, r9d
cmp r9d, 4
je 0x61c897ed
ja 0x61c897d1
cmp r9d, 3
je 0x61c897f5
test r9d, r9d
je 0x61c897d7
jmp 0x61c897ed
cmp r9d, 5
je 0x61c897f5
mov r8d, 0x179
lea rdx, str.src_Cairo.cpp
lea rcx, str.cairoformat___CAIRO_FORMAT_INVALID
jmp 0x61c89856
mov r14d, 1
jmp 0x61c897f8
xor r14d, r14d
mov rcx, rdi
call fcn.61ca6880
mov rcx, rdi
mov eax, dword [rax]
mov dword [rsp + 0x38], eax
call fcn.61ca6890
mov edx, dword [rsp + 0x38]
mov ecx, r14d
mov eax, dword [rax]
mov dword [rsp + 0x3c], eax
call fcn.61d114e0
mov ecx, dword [rsp + 0x3c]
imul ecx, dword [rsp + 0x38]
mov r15d, eax
imul ecx, eax
shl ecx, 2
movsxd rcx, ecx
call sub.msvcrt.dll_malloc
mov rbp, rax
test rax, rax
jne 0x61c8986b
mov r8d, 0x180
lea rdx, str.src_Cairo.cpp
lea rcx, str.newdata___nullptr
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.61c87360
mov dword [rsp + 0x20], r15d
mov r8d, dword [rsp + 0x38]
mov edx, r14d
mov rcx, rax
mov r9d, dword [rsp + 0x3c]
call fcn.61d120d0
mov r8d, 0x183
lea rdx, str.src_Cairo.cpp
lea rcx, str.newsurface___nullptr
mov r14, rax
test rax, rax
je 0x61c89856
mov rcx, rdi
call fcn.61ca6880
mov rcx, r14
mov r15d, dword [rax]
call fcn.61d12300
mov r8d, 0x184
lea rdx, str.src_Cairo.cpp
lea rcx, str.static_cast_int__s.getWidth_____cairo_image_surface_get_width_newsurface_
cmp r15d, eax
jne 0x61c89856
mov rcx, rdi
call fcn.61ca6890
mov rcx, r14
mov r15d, dword [rax]
call fcn.61d12280
mov r8d, 0x185
lea rdx, str.src_Cairo.cpp
lea rcx, str.static_cast_int__s.getHeight_____cairo_image_surface_get_height_newsurface_
cmp r15d, eax
jne 0x61c89856
mov rcx, qword [r13 + 0x20]
call fcn.61d17790
mov rdx, qword [r13 + 0x30]
test rdx, rdx
je 0x61c8991e
dec dword [rdx]
jne 0x61c8991e
mov rcx, qword [r13 + 0x28]
call sub.msvcrt.dll_free
jmp 0x61c8992c
mov ecx, 4
call sub.msvcrt.dll_malloc
mov qword [r13 + 0x30], rax
mov rax, qword [r13 + 0x30]
mov qword [r13 + 0x20], r14
mov qword [r13 + 0x28], rbp
mov dword [rax], 1
lea eax, [rsi - 1]
cmp eax, 4
ja case.default.0x61c89958
lea rdx, [0x61e07e30]
movsxd rax, dword [rdx + rax*4]
add rax, rdx
jmp rax
xor ecx, ecx
xor r8d, r8d
cmp r8d, dword [rsp + 0x3c]
jge case.default.0x61c89958
lea eax, [rcx*4]
movsxd r11, ecx
xor edx, edx
cdqe
add r11, r12
add rax, rbp
cmp dword [rsp + 0x38], edx
jle 0x61c899a1
mov r9b, byte [r11 + rdx]
mov byte [rax + 3], 0
inc rdx
add rax, 4
mov byte [rax - 4], r9b
mov byte [rax - 3], r9b
mov byte [rax - 2], r9b
jmp 0x61c8997e
inc r8d
add ecx, dword [rsp + 0x38]
jmp 0x61c8995f
xor r8d, r8d
xor r9d, r9d
cmp r9d, dword [rsp + 0x3c]
jge case.default.0x61c89958
lea edx, [r8 + r8*2]
lea eax, [r8*4]
xor ecx, ecx
movsxd rdx, edx
cdqe
add rdx, r12
add rax, rbp
cmp ecx, dword [rsp + 0x38]
jge 0x61c89a01
mov r11b, byte [rdx]
mov byte [rax + 3], 0
inc ecx
add rdx, 3
add rax, 4
mov byte [rax - 4], r11b
mov r11b, byte [rdx - 2]
mov byte [rax - 3], r11b
mov r11b, byte [rdx - 1]
mov byte [rax - 2], r11b
jmp 0x61c899d4
inc r9d
add r8d, dword [rsp + 0x38]
jmp 0x61c899b0
xor edx, edx
xor ecx, ecx
cmp ecx, dword [rsp + 0x3c]
jge case.default.0x61c89958
lea eax, [rdx*4]
xor r8d, r8d
cdqe
cmp r8d, dword [rsp + 0x38]
jge 0x61c89a72
movzx r11d, byte [r12 + rax + 3]
movzx r9d, byte [r12 + rax]
inc r8d
imul r9d, r11d
mov byte [rbp + rax + 3], r11b
mov ebx, r9d
movzx r9d, byte [r12 + rax + 1]
mov byte [rbp + rax], bh
imul r9d, r11d
mov ebx, r9d
movzx r9d, byte [r12 + rax + 2]
mov byte [rbp + rax + 1], bh
imul r9d, r11d
mov ebx, r9d
mov byte [rbp + rax + 2], bh
add rax, 4
jmp 0x61c89a25
inc ecx
add edx, dword [rsp + 0x38]
jmp 0x61c89a0f
xor r8d, r8d
xor r9d, r9d
cmp r9d, dword [rsp + 0x3c]
jge case.default.0x61c89958
lea edx, [r8 + r8*2]
lea eax, [r8*4]
xor ecx, ecx
movsxd rdx, edx
cdqe
add rdx, r12
add rax, rbp
cmp ecx, dword [rsp + 0x38]
jge 0x61c89ad2
mov r11b, byte [rdx + 2]
mov byte [rax + 3], 0
inc ecx
add rdx, 3
add rax, 4
mov byte [rax - 4], r11b
mov r11b, byte [rdx - 2]
mov byte [rax - 3], r11b
mov r11b, byte [rdx - 3]
mov byte [rax - 2], r11b
jmp 0x61c89aa4
inc r9d
add r8d, dword [rsp + 0x38]
jmp 0x61c89a80
xor edx, edx
xor ecx, ecx
cmp ecx, dword [rsp + 0x3c]
jge case.default.0x61c89958
lea eax, [rdx*4]
xor r8d, r8d
cdqe
cmp r8d, dword [rsp + 0x38]
jge 0x61c89b3f
movzx r11d, byte [r12 + rax + 3]
movzx r9d, byte [r12 + rax + 2]
inc r8d
imul r9d, r11d
mov byte [rbp + rax + 3], r11b
mov ebx, r9d
movzx r9d, byte [r12 + rax + 1]
mov byte [rbp + rax], bh
imul r9d, r11d
mov ebx, r9d
movzx r9d, byte [r12 + rax]
mov byte [rbp + rax + 1], bh
imul r9d, r11d
mov ebx, r9d
mov byte [rbp + rax + 2], bh
add rax, 4
jmp 0x61c89af2
inc ecx
add edx, dword [rsp + 0x38]
jmp 0x61c89ae0
mov r9d, esi
mov r8, rdi
mov rdx, r12
mov rcx, r13
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.61c9d0d0