Function at 0x1008c790
Capabilities:
Reference sql statements

Disassembly:
sub esp, 0x28
push ebx
push ebp
mov ebp, dword [esp + 0x34]
xor ecx, ecx
cmp byte [ebp + 0x3e], cl
push esi
push edi
mov esi, eax
mov dword [esp + 0x18], ecx
jne 0x1008c7c6
push str.cannot_VACUUM_from_within_a_transaction
mov eax, ebp
mov edi, esi
call fcn.1002e3a0
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x28
ret
cmp dword [ebp + 0x8c], 1
jle 0x1008c7d6
push str.cannot_VACUUM___SQL_statements_in_progress
jmp 0x1008c7ad
mov eax, dword [ebp + 0x18]
mov edx, dword [ebp + 0x50]
mov dword [esp + 0x24], eax
and eax, 0xfff5ffff
or eax, 0x202800
cmp byte [ebp + 0x3f], 2
mov dword [esp + 0x28], edx
mov edx, dword [ebp + 0x54]
mov dword [ebp + 0x18], eax
mov eax, dword [ebp + 0x10]
mov dword [esp + 0x2c], edx
mov edx, dword [ebp + 0xa4]
mov dword [ebp + 0xa4], ecx
mov edi, dword [eax + 4]
mov ecx, dword [edi + 4]
mov dword [esp + 0x30], edx
mov edx, dword [ecx]
movzx eax, byte [edx + 0xf]
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x20], eax
mov dword [esp + 0x3c], ecx
mov eax, str.ATTACH_:memory:_AS_vacuum_db_
je 0x1008c832
mov eax, str.ATTACH__AS_vacuum_db_
mov ecx, esi
mov ebx, ebp
call fcn.1008c130
mov ebx, eax
mov eax, dword [ebp + 0x14]
cmp eax, dword [esp + 0x3c]
jle 0x1008c856
mov ecx, dword [ebp + 0x10]
mov edx, eax
shl edx, 4
lea edx, [edx + ecx - 0x10]
mov dword [esp + 0x18], edx
test ebx, ebx
jne 0x1008caa1
mov ecx, dword [ebp + 0x10]
shl eax, 4
mov eax, dword [eax + ecx - 0xc]
mov dword [esp + 0x3c], eax
call fcn.1007ac20
mov eax, edi
call fcn.10024b90
cmp dword [ebp + 0x48], ebx
mov dword [esp + 0x14], eax
je 0x1008c899
lea edx, [esp + 0x1c]
lea ecx, [esp + 0x34]
mov eax, ebp
call fcn.10017020
cmp dword [esp + 0x1c], ebx
je 0x1008c899
mov dword [ebp + 0x48], ebx
mov eax, str.PRAGMA_vacuum_db.synchronousOFF
mov ecx, esi
mov ebx, ebp
call fcn.1008c130
mov ebx, eax
test ebx, ebx
jne 0x1008caa1
mov eax, str.BEGIN_
mov ecx, esi
mov ebx, ebp
call fcn.1008c130
mov ebx, eax
test ebx, ebx
jne 0x1008caa1
push 2
push edi
call fcn.1006aee0
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
mov edx, dword [edi + 4]
mov eax, dword [edx]
cmp byte [eax + 5], 5
jne 0x1008c8ec
mov dword [ebp + 0x48], ebx
mov ecx, dword [edi + 4]
mov edx, dword [esp + 0x14]
mov eax, dword [ecx + 0x20]
mov ebx, dword [esp + 0x3c]
push 0
push edx
mov ecx, ebx
call fcn.100305c0
add esp, 8
test eax, eax
jne 0x1008ca9c
cmp dword [esp + 0x20], eax
jne 0x1008c930
push eax
mov eax, dword [esp + 0x18]
push eax
mov eax, dword [ebp + 0x48]
mov ecx, ebx
call fcn.100305c0
add esp, 8
test eax, eax
jne 0x1008ca9c
cmp byte [ebp + 0x40], 0
jne 0x1008ca9c
mov al, byte [ebp + 0x42]
test al, al
jl 0x1008c946
movsx eax, al
jmp 0x1008c94d
mov eax, edi
call fcn.10024a10
push eax
mov eax, ebx
call fcn.10024a60
add esp, 4
push esi
push ebp
mov eax, str.SELECT_CREATE_TABLE_vacuum_db.__substr_sql_14____FROM_sqlite_master_WHERE_typetable_AND_name_sqlite_sequence___AND_coalesce_rootpage_1__0
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
push esi
push ebp
mov eax, str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
push esi
push ebp
mov eax, str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
push esi
push ebp
mov eax, 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_coalesce_rootpage_1__0
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
push esi
push ebp
mov eax, str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
push esi
push ebp
mov eax, str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM_main.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence_
call fcn.1008c460
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x1008caa1
mov eax, 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_
mov ecx, esi
mov ebx, ebp
call fcn.1008c130
mov ebx, eax
test ebx, ebx
jne 0x1008caa1
xor esi, esi
jmp 0x1008ca10
movzx edx, byte [esi + 0x100ac5f4]
lea ecx, [esp + 0x20]
push ecx
push edx
mov eax, edi
call fcn.10024920
movzx eax, byte [esi + 0x100ac5f5]
add eax, dword [esp + 0x28]
movzx ebx, byte [esi + 0x100ac5f4]
push eax
mov eax, dword [esp + 0x48]
call fcn.10044b70
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x1008caa1
add esi, 2
cmp esi, 0xa
jl 0x1008ca10
mov esi, dword [esp + 0x3c]
mov ebx, edi
call fcn.1007f590
mov ebx, eax
test ebx, ebx
jne 0x1008caa1
mov eax, esi
call fcn.1007ac20
mov ebx, eax
test ebx, ebx
jne 0x1008caa1
mov eax, esi
call fcn.10024a10
push eax
mov eax, edi
call fcn.10024a60
mov ecx, dword [esi + 4]
mov edx, dword [esp + 0x18]
mov eax, dword [ecx + 0x20]
add esp, 4
push 1
push edx
mov ecx, edi
call fcn.100305c0
add esp, 8
mov ebx, eax
jmp 0x1008caa1
mov ebx, 7
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
mov dword [ebp + 0x18], eax
mov eax, dword [esp + 0x30]
mov dword [ebp + 0x50], ecx
mov dword [ebp + 0xa4], eax
push 1
push 0xffffffffffffffff
or eax, 0xffffffff
mov ecx, edi
mov dword [ebp + 0x54], edx
call fcn.100305c0
mov esi, dword [esp + 0x20]
xor edi, edi
add esp, 8
cmp esi, edi
mov byte [ebp + 0x3e], 1
je 0x1008caed
mov eax, dword [esi + 4]
call fcn.100751a0
mov dword [esi + 4], edi
mov dword [esi + 0xc], edi
mov eax, ebp
call fcn.1003e5b0
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 0x28
ret