Function at 0x491920
Capabilities:
Reference sql statements

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x28
cmp dword [ecx + 0x24], 0
je 0x491935
add esp, 0x28
jmp 0x491a0e
mov esi, ecx
mov ebp, dword [ecx]
mov eax, dword [ecx + 0xec]
mov dword [esp + 0x14], eax
mov ecx, dword [eax + 0x3c]
mov eax, dword [ebp + 0x10]
test ecx, ecx
mov dword [esp + 4], edx
je 0x49196c
lea edx, [eax + 0xc]
mov ebx, 0xffffffff
nop dword [eax]
inc ebx
lea edi, [edx + 0x10]
cmp dword [edx], ecx
mov edx, edi
jne 0x491960
jmp 0x491971
mov ebx, 0xffff8000
mov ecx, ebx
shl ecx, 4
mov dword [esp + 0x24], ecx
mov eax, dword [eax + ecx]
mov dword [esp], eax
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
mov edi, dword [ecx + 4]
add edx, 0x10
movsx eax, word [ecx + 0x22]
dec eax
lea eax, [eax + eax*2]
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], eax
movzx eax, word [edi + eax*4 + 8]
xor edi, edi
test eax, eax
je 0x4919ad
cmp byte [ecx + 0x2b], 0
je 0x491a13
mov ecx, ebp
mov dword [esp + 8], edx
push dword [esp]
call fcn.0043cbf0
add esp, 4
mov ecx, dword [ebp + 0x168]
test ecx, ecx
mov edx, dword [esp + 4]
je 0x4919de
cmp byte [ebp + 0xb1], 0
jne 0x4919de
cmp byte [esi + 0xd0], 0
je 0x491a57
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
movzx eax, word [eax + ecx*4 + 0xa]
test al, 1
jne 0x491a00
mov ecx, dword [esp + 0x14]
cmp dword [ecx + 8], 0
je 0x491a27
push str.Cannot_add_a_UNIQUE_column
jmp 0x491a05
push str.Cannot_add_a_PRIMARY_KEY_column
push esi
call fcn.00434540
add esp, 0x30
pop esi
pop edi
pop ebx
pop ebp
ret
mov ecx, dword [ecx + 0x34]
test ecx, ecx
je 0x4919ad
cmp dword [ecx], eax
jl 0x4919ad
shl eax, 4
mov edi, dword [eax + ecx - 8]
jmp 0x4919ad
test al, 0x60
je 0x491a83
test al, 0x40
je 0x491b79
push dword [esp + 8]
push dword [esp + 4]
push str.cannot_add_a_STORED_column
push str.SELECT_raise_ABORT__Q__FROM___w_.__w_
push esi
call fcn.0049fb10
mov edx, dword [esp + 0x18]
add esp, 0x14
jmp 0x491b79
push dword [esi + 0xf8]
push 0
push dword [eax]
push dword [esp + 0xc]
push 0x1a
push dword [ebp + 0x16c]
call ecx
add esp, 0x18
cmp eax, 1
jne 0x491a96
mov edi, 0x17
mov eax, str.not_authorized
jmp 0x491aab
test edi, edi
je 0x491abd
mov eax, dword [edi + 0xc]
xor edx, edx
cmp byte [eax], 0x79
cmovne edx, edi
mov edi, edx
jmp 0x491abf
test eax, 0xfffffffd
je 0x491e2e
mov edi, 1
mov eax, str.authorizer_malfunction
push eax
push esi
call fcn.00434540
add esp, 8
mov dword [esi + 0xc], edi
jmp 0x49192d
xor edi, edi
mov eax, dword [esp + 8]
mov edx, dword [esp]
test byte [ebp + 0x21], 0x40
je 0x491aed
cmp dword [ecx + 0x30], 0
je 0x491aed
test edi, edi
je 0x491aed
push eax
push edx
push str.Cannot_add_a_REFERENCES_column_with_non_NULL_default_value
push str.SELECT_raise_ABORT__Q__FROM___w_.__w_
push esi
call fcn.0049fb10
add esp, 0x14
jmp 0x491b26
mov ecx, dword [esp + 0x10]
mov edx, edi
mov edi, dword [esp + 0xc]
test byte [ecx + edi*4 + 4], 0xf
mov edi, edx
je 0x491b1e
test edi, edi
jne 0x491b1e
push eax
push dword [esp + 4]
push str.Cannot_add_a_NOT_NULL_column_with_default_value_NULL
push str.SELECT_raise_ABORT__Q__FROM___w_.__w_
push esi
call fcn.0049fb10
add esp, 0x14
jmp 0x491b75
test edi, edi
mov edx, dword [esp + 4]
je 0x491b79
mov dword [esp + 0x1c], 0
lea eax, [esp + 0x1c]
mov ecx, ebp
mov edx, edi
push eax
push 0x41
push 1
call fcn.00476670
add esp, 0xc
test eax, eax
jne 0x49192d
mov edi, dword [esp + 0x1c]
test edi, edi
jne 0x491b6e
push dword [esp + 8]
push dword [esp + 4]
push str.Cannot_add_a_column_with_non_constant_default
push str.SELECT_raise_ABORT__Q__FROM___w_.__w_
push esi
call fcn.0049fb10
add esp, 0x14
mov ecx, edi
call fcn.00430970
mov edx, dword [esp + 4]
mov eax, dword [edx]
test eax, eax
je 0x491c12
mov edx, dword [edx + 4]
mov dword [esp + 0x20], eax
xor eax, eax
mov dword [esp + 0x18], edx
inc edx
sete al
mov ecx, ebp
push eax
call fcn.0043f5f0
add esp, 4
mov edi, eax
mov eax, dword [esp + 0x20]
test edi, edi
je 0x491c12
push dword [esp + 0x18]
push eax
push edi
call sub.api_ms_win_crt_private_l1_1_0.dll_memcpy
add esp, 0xc
mov eax, dword [esp + 0x18]
mov byte [edi + eax], 0
mov eax, dword [esp + 4]
mov eax, dword [eax + 4]
dec eax
test eax, eax
jle 0x491be9
add eax, edi
jmp 0x491bd8
mov byte [eax], 0
dec eax
cmp eax, edi
jbe 0x491be9
movzx ecx, byte [eax]
cmp ecx, 0x3b
je 0x491bd0
test byte [ecx + 0x52aaeb], 1
jne 0x491bd0
mov eax, dword [esp + 0x14]
mov eax, dword [eax + 0x2c]
push dword [esp + 8]
push eax
push edi
push eax
push dword [esp + 0x10]
push str.UPDATE___w_.sqlite_master_SET_sql__printf___._ds___sql____Q__substr_sql_1length_printf___._ds_sql____WHERE_type__table_AND_name___Q
push esi
call fcn.0049fb10
add esp, 0x1c
mov ecx, ebp
mov edx, edi
call fcn.0043f4f0
mov edi, dword [esi + 8]
test edi, edi
jne 0x491c3c
cmp dword [esi + 0x74], 0
jne 0x491c2b
mov eax, dword [esi]
test byte [eax + 0x50], 8
jne 0x491c2b
mov byte [esi + 0x17], 1
mov ecx, esi
call fcn.004346f0
mov edi, eax
test eax, eax
je 0x49192d
movzx eax, byte [esi + 0x13]
test al, al
je 0x491c55
dec al
mov byte [esi + 0x13], al
movzx eax, al
mov ebp, dword [esi + eax*4 + 0x98]
jmp 0x491c5c
mov ebp, dword [esi + 0x2c]
inc ebp
mov dword [esi + 0x2c], ebp
mov eax, dword [edi + 0x6c]
cmp dword [edi + 0x70], eax
jle 0x491c91
lea ecx, [eax + 1]
mov dword [edi + 0x6c], ecx
mov ecx, dword [edi + 0x68]
lea eax, [eax + eax*4]
mov dword [ecx + eax*4], 0x63
mov dword [ecx + eax*4 + 4], ebx
mov dword [ecx + eax*4 + 8], ebp
mov dword [ecx + eax*4 + 0xc], 2
mov dword [ecx + eax*4 + 0x10], 0
jmp 0x491ca4
mov ecx, edi
mov edx, 0x63
push 2
push ebp
push ebx
call fcn.004747e0
add esp, 0xc
mov eax, 1
mov ecx, ebx
shl eax, cl
or dword [edi + 0x98], eax
cmp ebx, 1
je 0x491cd1
mov ecx, dword [edi]
mov ecx, dword [ecx + 0x10]
mov edx, dword [esp + 0x24]
mov ecx, dword [ecx + edx + 4]
cmp byte [ecx + 9], 0
je 0x491cd1
or dword [edi + 0x9c], eax
mov eax, dword [edi + 0x6c]
cmp dword [edi + 0x70], eax
jle 0x491d0a
lea ecx, [eax + 1]
mov dword [edi + 0x6c], ecx
mov ecx, dword [edi + 0x68]
lea eax, [eax + eax*4]
mov dword [ecx + eax*4], 0x56
mov dword [ecx + eax*4 + 4], ebp
mov dword [ecx + eax*4 + 8], 0xfffffffe
mov dword [ecx + eax*4 + 0xc], 0
mov dword [ecx + eax*4 + 0x10], 0
jmp 0x491d1e
mov ecx, edi
mov edx, 0x56
push 0
push 0xfffffffffffffffe
push ebp
call fcn.004747e0
add esp, 0xc
mov ecx, dword [edi + 0x6c]
lea eax, [ecx + 2]
cmp dword [edi + 0x70], ecx
jle 0x491d56
lea edx, [ecx + 1]
mov dword [edi + 0x6c], edx
mov edx, dword [edi + 0x68]
lea ecx, [ecx + ecx*4]
mov dword [edx + ecx*4], 0x31
mov dword [edx + ecx*4 + 4], ebp
mov dword [edx + ecx*4 + 8], eax
mov dword [edx + ecx*4 + 0xc], 0
mov dword [edx + ecx*4 + 0x10], 0
jmp 0x491d69
mov ecx, edi
mov edx, 0x31
push 0
push eax
push ebp
call fcn.004747e0
add esp, 0xc
mov eax, dword [edi + 0x6c]
cmp dword [edi + 0x70], eax
jle 0x491da2
lea ecx, [eax + 1]
mov dword [edi + 0x6c], ecx
mov ecx, dword [edi + 0x68]
lea eax, [eax + eax*4]
mov dword [ecx + eax*4], 0x64
mov dword [ecx + eax*4 + 4], ebx
mov dword [ecx + eax*4 + 8], 2
mov dword [ecx + eax*4 + 0xc], 3
mov dword [ecx + eax*4 + 0x10], 0
jmp 0x491db6
mov ecx, edi
mov edx, 0x64
push 3
push 2
push ebx
call fcn.004747e0
add esp, 0xc
test ebp, ebp
je 0x491dd1
movzx eax, byte [esi + 0x13]
cmp eax, 7
ja 0x491dd1
mov ecx, eax
inc cl
mov byte [esi + 0x13], cl
mov dword [esi + eax*4 + 0x98], ebp
mov ecx, esi
mov edx, ebx
push 3
call fcn.004db130
add esp, 4
mov eax, dword [esp + 0x14]
cmp dword [eax + 0x10], 0
je 0x491e03
push dword [esp]
push dword [esp + 0xc]
push str.SELECT_CASE_WHEN_quick_check_GLOB_CHECK_THEN_raise_ABORT_CHECK_constraint_failed__ELSE_raise_ABORT_NOT_NULL_constraint_failed__END__FROM_pragma_quick_check__Q__Q__WHERE_quick_check_GLOB_CHECK_OR_quick_check_GLOB_NULL
push esi
call fcn.0049fb10
add esp, 0x38
jmp 0x491a0e
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
test byte [eax + ecx*4 + 4], 0xf
je 0x49192d
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
lea eax, [eax + ecx*4]
add eax, 0xa
test byte [eax], 0x60
jne 0x491de9
jmp 0x49192d
test eax, eax
mov edx, dword [esp + 4]
jne 0x49192d
jmp 0x4919de