Function at 0x1002271c
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
and dword [ebp - 8], 0
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov eax, dword [esi + 0xc]
mov dword [ebp - 0x10], eax
or eax, 0x2800
cmp byte [esi + 0x1c], 0
push edi
mov dword [esi + 0xc], eax
jne 0x1002275a
push 0
push str.cannot_VACUUM_from_within_a_transaction
push dword [ebp + 8]
call fcn.10013a85
xor edi, edi
add esp, 0xc
inc edi
jmp 0x1002290a
mov eax, dword [esi + 8]
mov ebx, dword [eax + 4]
push str.ATTACH__AS_vacuum_db_
push esi
mov dword [ebp - 4], ebx
call fcn.10022650
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
mov eax, dword [esi + 4]
mov ecx, dword [esi + 8]
imul eax, eax, 0x18
add eax, ecx
mov edi, dword [eax - 0x14]
lea ecx, [eax - 0x18]
push ebx
mov dword [ebp - 8], ecx
mov dword [ebp + 0xc], edi
call fcn.10003874
pop ecx
push eax
push ebx
call fcn.10003868
pop ecx
push eax
push edi
call fcn.100037f2
add esp, 0xc
cmp byte [esi + 0x1e], 0
je 0x100227b8
push 7
pop edi
jmp 0x1002290a
push str.PRAGMA_vacuum_db.synchronousOFF
push esi
call fcn.10022650
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push ebx
call fcn.1000390c
push eax
push dword [ebp + 0xc]
call fcn.100038c4
push str.BEGIN_EXCLUSIVE_
push esi
call fcn.10022650
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x1002290a
push str.SELECT_CREATE_TABLE_vacuum_db.__substr_sql_14____FROM_sqlite_master_WHERE_typetable_AND_name_sqlite_sequence___AND_rootpage_0
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM___quote_name____FROM_sqlite_master_WHERE_type__table_AND_name_sqlite_sequence___AND_rootpage_0
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM___quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence_
push esi
call fcn.1002269b
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push str.INSERT_INTO_vacuum_db.sqlite_master___SELECT_type__name__tbl_name__rootpage__sql____FROM_sqlite_master___WHERE_typeview_OR_typetrigger______OR__typetable_AND_rootpage0_
push esi
call fcn.10022650
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
xor ebx, ebx
lea eax, [ebp - 0xc]
push eax
movzx eax, byte [ebx + 0x1003379c]
push eax
push dword [ebp - 4]
call fcn.100064fc
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x1002290a
movzx eax, byte [ebx + 0x1003379d]
add eax, dword [ebp - 0xc]
push eax
movzx eax, byte [ebx + 0x1003379c]
push eax
push dword [ebp + 0xc]
call fcn.10006584
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x1002290a
inc ebx
inc ebx
cmp ebx, 8
jb 0x10022895
push dword [ebp + 0xc]
push dword [ebp - 4]
call fcn.100082e0
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x1002290a
push dword [ebp + 0xc]
call fcn.10007215
mov edi, eax
test edi, edi
pop ecx
jne 0x1002290a
push dword [ebp - 4]
call fcn.10007215
pop ecx
mov edi, eax
mov ebx, dword [ebp - 8]
test ebx, ebx
mov eax, dword [ebp - 0x10]
mov dword [esi + 0xc], eax
mov byte [esi + 0x1c], 1
je 0x1002292c
push dword [ebx + 4]
call fcn.10008319
and dword [ebx + 4], 0
and dword [ebx + 0x14], 0
pop ecx
push 0
push esi
call fcn.10008882
pop ecx
pop ecx
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret