Function at 0x42181e
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
and dword [ebp - 0xc], 0
push esi
mov esi, dword [ebp + 0xc]
cmp byte [esi + 0x1c], 0
jne 0x421839
push str.cannot_VACUUM_from_within_a_transaction
jmp 0x421847
cmp dword [esi + 0x8c], 1
jle 0x42185b
push str.cannot_VACUUM___SQL_statements_in_progress
push esi
push dword [ebp + 8]
call fcn.0040f7d6
add esp, 0xc
push 1
pop eax
jmp 0x421b55
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 0x3c]
mov dword [ebp - 0x14], eax
and eax, 0xfaffffff
mov dword [ebp - 0x18], ecx
mov ecx, dword [esi + 0x40]
or eax, 0x10050000
mov dword [ebp - 0x1c], ecx
mov ecx, dword [esi + 0x98]
and dword [esi + 0x98], 0
mov dword [esi + 0xc], eax
mov eax, dword [esi + 8]
push ebx
push edi
mov eax, dword [eax + 4]
mov dword [ebp - 0x20], ecx
push eax
mov dword [ebp + 0xc], eax
call fcn.004063df
push eax
call fcn.0040d15d
mov ebx, dword [esi + 4]
push esi
mov dword [ebp - 0x10], eax
call fcn.0043e850
add esp, 0xc
test eax, eax
mov eax, str.ATTACH_:memory:_AS_vacuum_db_
jne 0x4218be
mov eax, str.ATTACH__AS_vacuum_db_
push eax
push dword [ebp + 8]
push esi
call fcn.00421c72
mov edi, eax
mov eax, dword [esi + 4]
add esp, 0xc
cmp eax, ebx
jle 0x4218e3
mov edx, dword [esi + 8]
mov ecx, eax
shl ecx, 4
lea ecx, [ecx + edx - 0x10]
mov dword [ebp - 0xc], ecx
xor ebx, ebx
cmp edi, ebx
jne 0x421aff
mov ecx, dword [esi + 8]
shl eax, 4
mov edi, dword [eax + ecx - 0xc]
push edi
mov dword [ebp - 4], edi
call fcn.00420a69
push dword [ebp + 0xc]
call fcn.00421b58
push dword [ebp + 0xc]
mov dword [ebp - 8], eax
call fcn.004063df
push eax
call fcn.0040974e
add esp, 0x10
cmp eax, 5
jne 0x421924
mov dword [esi + 0x24], ebx
push ebx
push dword [ebp - 8]
push dword [ebp + 0xc]
call fcn.00406a03
pop ecx
push eax
push edi
call fcn.0040667b
add esp, 0x10
test eax, eax
jne 0x421afc
cmp dword [ebp - 0x10], ebx
jne 0x421960
push ebx
push dword [ebp - 8]
push dword [esi + 0x24]
push edi
call fcn.0040667b
add esp, 0x10
test eax, eax
jne 0x421afc
cmp byte [esi + 0x1e], 0
jne 0x421afc
mov ebx, dword [ebp + 8]
push str.PRAGMA_vacuum_db.synchronousOFF
push ebx
push esi
call fcn.00421c72
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
mov al, byte [esi + 0x20]
test al, al
jl 0x421992
movsx eax, al
jmp 0x42199b
push dword [ebp + 0xc]
call fcn.00421bcc
pop ecx
push eax
push dword [ebp - 4]
call fcn.00421b7a
push str.BEGIN_EXCLUSIVE_
push ebx
push esi
call fcn.00421c72
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x421aff
push str.SELECT_CREATE_TABLE_vacuum_db.__substr_sql_14____FROM_sqlite_master_WHERE_typetable_AND_name_sqlite_sequence___AND_rootpage_0
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM_main.__quote_name____FROM_main.sqlite_master_WHERE_type__table_AND_name_sqlite_sequence___AND_rootpage_0
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM_main.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence_
push ebx
push esi
call fcn.00421d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
push str.INSERT_INTO_vacuum_db.sqlite_master___SELECT_type__name__tbl_name__rootpage__sql____FROM_main.sqlite_master___WHERE_typeview_OR_typetrigger______OR__typetable_AND_rootpage0_
push ebx
push esi
call fcn.00421c72
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x421aff
xor ebx, ebx
lea eax, [ebp + 8]
push eax
movzx eax, byte [ebx + 0x484214]
push eax
push dword [ebp + 0xc]
call fcn.0040cf50
movzx eax, byte [ebx + 0x484215]
add eax, dword [ebp + 8]
push eax
movzx eax, byte [ebx + 0x484214]
push eax
push dword [ebp - 4]
call fcn.0040cf85
mov edi, eax
add esp, 0x18
test edi, edi
jne 0x421aff
inc ebx
inc ebx
cmp ebx, 8
jl 0x421a6e
mov ebx, dword [ebp - 4]
push ebx
push dword [ebp + 0xc]
call fcn.00421bfd
mov edi, eax
pop ecx
test edi, edi
pop ecx
jne 0x421aff
push ebx
call fcn.00420a69
mov edi, eax
pop ecx
test edi, edi
jne 0x421aff
push ebx
call fcn.00421bcc
push eax
push dword [ebp + 0xc]
call fcn.00421b7a
add esp, 0xc
push 1
push dword [ebp - 8]
push ebx
call fcn.00406a03
pop ecx
push eax
push dword [ebp + 0xc]
call fcn.0040667b
add esp, 0x10
mov edi, eax
jmp 0x421aff
push 7
pop edi
mov eax, dword [ebp - 0x14]
push 1
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x18]
mov dword [esi + 0x3c], eax
mov eax, dword [ebp - 0x1c]
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 0xc]
mov dword [esi + 0x40], eax
mov eax, dword [ebp - 0x20]
mov dword [esi + 0x98], eax
call fcn.0040667b
mov ebx, dword [ebp - 0xc]
add esp, 0x10
test ebx, ebx
mov byte [esi + 0x1c], 1
je 0x421b47
push dword [ebx + 4]
call fcn.0040e62c
and dword [ebx + 4], 0
and dword [ebx + 0xc], 0
pop ecx
push 0
push esi
call fcn.0041e27e
pop ecx
mov eax, edi
pop ecx
pop edi
pop ebx
pop esi
leave
ret