Function at 0x1402167d0
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x78
mov edi, dword [rcx + 0x30]
mov r12, qword [rcx]
test edi, edi
mov rbx, rcx
mov rsi, rdx
jne 0x140216b06
mov r13, qword [rcx + 0x160]
mov rax, qword [r12 + 0x20]
mov r8, qword [r13 + 0x60]
test r8, r8
je 0x140216cfe
cmp r8, qword [rax + 0x18]
je 0x140216c10
lea rcx, [rax + 0x20]
mov edx, 1
mov rax, rcx
mov r9, rdx
add rdx, 1
cmp r8, qword [rax + 0x18]
lea rcx, [rcx + 0x20]
jne 0x140216820
mov edi, r9d
shl r9, 5
mov qword [rsp + 0x48], r9
mov r14, qword [rax]
mov rax, qword [r13]
add rax, 0x10
mov qword [rsp + 0x40], rax
movsx rax, word [r13 + 0x36]
lea rdx, [rax + rax*2]
mov rax, qword [r13 + 8]
lea r15, [rax + rdx*8 - 0x18]
movzx eax, word [r15 + 0x10]
test ax, ax
je 0x140216b20
cmp byte [r13 + 0x3f], 0
jne 0x140216b20
mov rbp, qword [r13 + 0x50]
test rbp, rbp
je 0x14021689b
cmp dword [rbp], eax
jl 0x140216b20
sub eax, 1
cdqe
shl rax, 5
mov rbp, qword [rbp + rax + 8]
mov rdx, qword [rsp + 0x40]
mov r8, r14
mov rcx, r12
call fcn.1401981f0
mov r8, r14
mov edx, 0x1a
mov rcx, rbx
mov r9, qword [rax]
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x20], 0
call fcn.14017d870
test eax, eax
jne 0x140216b06
movzx eax, word [r15 + 0x12]
lea rdx, str.Cannot_add_a_PRIMARY_KEY_column
test al, 1
jne 0x140216b37
cmp qword [r13 + 0x10], 0
jne 0x140216b30
test al, 0x60
je 0x140216b50
test al, 0x40
jne 0x140216cc0
mov r9, qword [rsi]
mov eax, dword [rsi + 8]
test r9, r9
mov qword [rsp + 0x58], r9
je 0x1402169b7
mov ebp, eax
mov rcx, r12
lea rdx, [rbp + 1]
call fcn.140168520
test rax, rax
je 0x1402169b7
mov rdx, qword [rsp + 0x58]
mov rcx, rax
mov r8, rbp
call sub.msvcrt.dll_memcpy
lea rcx, [0x1403b5780]
mov r11, rax
mov byte [rax + rbp], 0
mov eax, dword [rsi + 8]
sub eax, 1
add rax, r11
cmp r11, rax
jae 0x14021697b
nop word [rax + rax]
movzx edx, byte [rax]
cmp dl, 0x3b
je 0x14021696e
test byte [rcx + rdx], 1
je 0x14021697b
sub rax, 1
mov byte [rax + 1], 0
cmp rax, r11
jne 0x140216960
mov r9d, dword [r13 + 0x40]
mov rcx, rbx
mov qword [rsp + 0x20], r11
mov r8, r14
mov rax, qword [rsp + 0x40]
lea rdx, str.UPDATE___w_.sqlite_master_SET_sql__printf___._ds___sql____Q__substr_sql_1length_printf___._ds_sql____WHERE_type__table_AND_name___Q
mov qword [rsp + 0x58], r11
mov dword [rsp + 0x28], r9d
mov qword [rsp + 0x30], rax
call fcn.140210f90
mov rdx, qword [rsp + 0x58]
mov rcx, r12
call fcn.1401584a0
mov r12, qword [rbx + 0x10]
test r12, r12
je 0x140216be8
movzx eax, byte [rbx + 0x1f]
test al, al
je 0x140216c51
sub eax, 1
mov byte [rbx + 0x1f], al
movzx eax, al
mov esi, dword [rbx + rax*4 + 0xe8]
mov rcx, r12
mov dword [rsp + 0x20], 2
mov r9d, esi
mov r8d, edi
mov edx, 0x63
call fcn.140177290
mov eax, 1
mov ecx, edi
shl eax, cl
or dword [r12 + 0xcc], eax
cmp edi, 1
je 0x140216a31
mov rdx, qword [r12]
mov rcx, qword [rsp + 0x48]
mov rdx, qword [rdx + 0x20]
mov rdx, qword [rdx + rcx + 8]
cmp byte [rdx + 0x11], 0
je 0x140216a31
or dword [r12 + 0xd0], eax
mov r8d, esi
mov edx, 0x56
mov dword [rsp + 0x20], 0
mov r9d, 0xfffffffe
mov rcx, r12
call fcn.140177290
mov r8d, esi
mov edx, 0x3b
mov rcx, r12
mov eax, dword [r12 + 0x90]
mov dword [rsp + 0x20], 0
lea r9d, [rax + 2]
call fcn.140177290
mov r8d, edi
mov edx, 0x64
mov rcx, r12
mov dword [rsp + 0x20], 3
mov r9d, 2
call fcn.140177290
test esi, esi
je 0x140216aa1
movzx eax, byte [rbx + 0x1f]
cmp al, 7
jbe 0x140216c5f
cmp qword [rbx + 0x10], 0
je 0x140216ab8
mov r8d, 3
mov edx, edi
mov rcx, rbx
call fcn.140179120
cmp qword [r13 + 0x20], 0
je 0x140216af0
mov r8, qword [rsp + 0x40]
lea rdx, str.SELECT_CASE_WHEN_quick_check_GLOB_CHECK_THEN_raise_ABORT_CHECK_constraint_failed__WHEN_quick_check_GLOB_non__value_in_THEN_raise_ABORT_type_mismatch_on_DEFAULT__ELSE_raise_ABORT_NOT_NULL_constraint_failed__END__FROM_pragma_quick_check__Q__Q__WHERE_quick_check_GLOB_CHECK_OR_quick_check_GLOB_NULL_OR_quick_check_GLOB_non__value_in
mov r9, r14
mov rcx, rbx
add rsp, 0x78
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.140210f90
test byte [r15 + 8], 0xf
jne 0x140216c71
mov rax, qword [rsp + 0x50]
test byte [rax + 0x32], 1
jne 0x140216abf
add rsp, 0x78
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
xor ebp, ebp
jmp 0x14021689b
lea rdx, str.Cannot_add_a_UNIQUE_column
mov rcx, rbx
add rsp, 0x78
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.140168320
test rbp, rbp
je 0x140216c1e
mov rax, qword [rbp + 0x10]
cmp byte [rax], 0x79
je 0x140216c1e
test byte [r12 + 0x31], 0x40
je 0x140216b98
cmp qword [r13 + 0x48], 0
je 0x140216b98
mov rax, qword [rsp + 0x40]
mov r9, r14
mov rcx, rbx
lea r8, str.Cannot_add_a_REFERENCES_column_with_non_NULL_default_value
lea rdx, str.SELECT_raise_ABORT__Q__FROM___w_.__w_
mov qword [rsp + 0x20], rax
call fcn.140210f90
lea rax, [rsp + 0x68]
mov r9d, 0x41
mov r8d, 1
mov qword [rsp + 0x68], 0
mov qword [rsp + 0x20], rax
mov rdx, rbp
mov rcx, r12
call fcn.1401886b0
test eax, eax
jne 0x140216b06
mov rcx, qword [rsp + 0x68]
test rcx, rcx
je 0x140216c81
call fcn.140160720
jmp 0x140216903
cmp qword [rbx + 0xb0], 0
je 0x140216ce8
mov rcx, rbx
call fcn.140177310
test rax, rax
mov r12, rax
jne 0x1402169c4
jmp 0x140216b06
mov qword [rsp + 0x48], 0
jmp 0x140216840
test byte [r15 + 8], 0xf
je 0x140216903
mov rax, qword [rsp + 0x40]
mov r9, r14
mov rcx, rbx
lea r8, str.Cannot_add_a_NOT_NULL_column_with_default_value_NULL
lea rdx, str.SELECT_raise_ABORT__Q__FROM___w_.__w_
mov qword [rsp + 0x20], rax
call fcn.140210f90
jmp 0x140216903
mov eax, dword [rbx + 0x38]
lea esi, [rax + 1]
mov dword [rbx + 0x38], esi
jmp 0x1402169e0
lea edx, [rax + 1]
mov byte [rbx + 0x1f], dl
mov dword [rbx + rax*4 + 0xe8], esi
jmp 0x140216aa1
test byte [r15 + 0x12], 0x60
jne 0x140216abf
jmp 0x140216afb
mov rax, qword [rsp + 0x40]
mov rcx, rbx
mov r9, r14
lea r8, str.Cannot_add_a_column_with_non_constant_default
lea rdx, str.SELECT_raise_ABORT__Q__FROM___w_.__w_
mov qword [rsp + 0x20], rax
call fcn.140210f90
mov rcx, qword [rsp + 0x68]
test rcx, rcx
je 0x140216903
jmp 0x140216bd8
mov rax, qword [rsp + 0x40]
mov r9, r14
mov rcx, rbx
lea r8, str.cannot_add_a_STORED_column
lea rdx, str.SELECT_raise_ABORT__Q__FROM___w_.__w_
mov qword [rsp + 0x20], rax
call fcn.140210f90
jmp 0x140216903
mov rax, qword [rbx]
test byte [rax + 0x60], 8
jne 0x140216bf6
mov byte [rbx + 0x23], 1
jmp 0x140216bf6
sub rax, 0x100000
mov edi, 0xffff8000
mov qword [rsp + 0x48], 0xfffffffffff00000
jmp 0x140216840