Function at 0x4a2800
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
xor ecx, ecx
mov esi, eax
push edi
mov dword [ebp - 0xc], ecx
cmp byte [esi + 0x1c], cl
jne 0x4a2831
mov esi, dword [ebp + 8]
push str.cannot_VACUUM_from_within_a_transaction
call fcn.00457550
mov eax, 1
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi + 0xc]
mov edx, dword [esi + 0x3c]
mov dword [ebp - 0x18], eax
and eax, 0xfaffffff
or eax, 0x50000
cmp byte [esi + 0x1d], 2
mov dword [ebp - 0x1c], edx
mov edx, dword [esi + 0x40]
mov dword [esi + 0xc], eax
mov eax, dword [esi + 8]
mov dword [ebp - 0x20], edx
mov edx, dword [esi + 0x94]
mov dword [esi + 0x94], ecx
mov edi, dword [eax + 4]
mov ecx, dword [edi + 4]
mov dword [ebp - 0x24], edx
mov edx, dword [ecx]
movzx eax, byte [edx + 0xd]
mov dword [ebp - 0x10], eax
mov dword [ebp - 8], edi
mov eax, str.ATTACH_:memory:_AS_vacuum_db_
je 0x4a2884
mov eax, str.ATTACH__AS_vacuum_db_
mov ecx, dword [ebp + 8]
push ecx
push esi
call fcn.004a24b0
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
add edx, edx
lea ecx, [eax + edx*8 - 0x10]
mov eax, dword [eax + edx*8 - 0xc]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 4], eax
call fcn.00464ba0
call fcn.004617d0
mov ebx, edi
mov eax, dword [ebx + 4]
movzx edx, word [eax + 0x18]
movzx edi, word [eax + 0x16]
sub edi, edx
cmp byte [ebx + 9], 0
mov dword [ebp - 0x14], edi
je 0x4a28ed
dec dword [ebx + 0xc]
jne 0x4a28ed
mov eax, dword [eax + 0x30]
test eax, eax
je 0x4a28e9
push eax
call dword [0x54ee30]
add esp, 4
mov byte [ebx + 0xa], 0
mov eax, dword [ebx + 4]
movzx eax, word [eax + 0x16]
mov ebx, dword [ebp - 4]
push 0
push edi
push eax
call fcn.004638e0
add esp, 0xc
test eax, eax
jne 0x4a2ac9
cmp dword [ebp - 0x10], eax
jne 0x4a2926
mov ecx, dword [esi + 0x24]
push eax
push edi
push ecx
call fcn.004638e0
add esp, 0xc
test eax, eax
jne 0x4a2ac9
cmp byte [esi + 0x1e], 0
jne 0x4a2ac9
mov edi, dword [ebp + 8]
push edi
push esi
mov eax, str.PRAGMA_vacuum_db.synchronousOFF
call fcn.004a24b0
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
mov al, byte [esi + 0x21]
test al, al
js 0x4a2958
movsx eax, al
jmp 0x4a2960
mov eax, dword [ebp - 8]
call fcn.00463ad0
push eax
mov eax, dword [ebp - 4]
call fcn.00463a50
add esp, 4
push edi
push esi
mov eax, str.BEGIN_EXCLUSIVE_
call fcn.004a24b0
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
mov eax, str.SELECT_CREATE_TABLE_vacuum_db.__substr_sql_14____FROM_sqlite_master_WHERE_typetable_AND_name_sqlite_sequence___AND_rootpage_0
call fcn.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
mov eax, str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
call fcn.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
mov eax, str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
call fcn.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
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_rootpage_0
call fcn.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
mov eax, str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
call fcn.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
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.004a2560
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
push edi
push esi
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_
call fcn.004a24b0
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4a2ace
xor edi, edi
movzx eax, byte [edi + 0x527308]
lea edx, [ebp - 0x10]
push edx
push eax
mov eax, dword [ebp - 8]
call fcn.004691c0
movzx ecx, byte [edi + 0x527309]
add ecx, dword [ebp - 0x10]
movzx edx, byte [edi + 0x527308]
mov eax, dword [ebp - 4]
push ecx
push edx
call fcn.00469230
mov ebx, eax
add esp, 0x10
test ebx, ebx
jne 0x4a2ace
add edi, 2
cmp edi, 8
jl 0x4a2a36
mov eax, dword [ebp - 8]
mov edi, dword [ebp - 4]
push eax
mov ebx, edi
call fcn.0046b2d0
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x4a2ace
mov eax, edi
call fcn.00464ba0
mov ebx, eax
test ebx, ebx
jne 0x4a2ace
mov eax, edi
call fcn.00463ad0
mov ebx, dword [ebp - 8]
push eax
mov eax, ebx
call fcn.00463a50
mov ecx, dword [edi + 4]
movzx eax, word [ecx + 0x16]
mov edx, dword [ebp - 0x14]
add esp, 4
push 1
push edx
push eax
call fcn.004638e0
add esp, 0xc
mov ebx, eax
jmp 0x4a2ace
mov ebx, 7
mov eax, dword [ebp - 0x18]
mov edi, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x20]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x24]
mov dword [esi + 0x3c], ecx
mov dword [esi + 0x40], edx
mov dword [esi + 0x94], eax
mov byte [esi + 0x1c], 1
test edi, edi
je 0x4a2b04
mov eax, dword [edi + 4]
call fcn.004636b0
xor eax, eax
mov dword [edi + 4], eax
mov dword [edi + 0xc], eax
push 0
mov eax, esi
call fcn.00483290
add esp, 4
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret