Function at 0x4e2c10
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push ebx
push esi
push edi
mov edi, edx
mov dword [ebp - 0x20], 0
mov ebx, ecx
mov dword [ebp - 8], ebx
cmp byte [edi + 0x4f], 0
jne 0x4e2ca0
mov edx, dword [ebx]
test edx, edx
je 0x4e2c6e
cmp dword [edi + 0x1e8], 0
je 0x4e2c45
mov ecx, edi
call fcn.0047cce0
jmp 0x4e2c6e
cmp edx, dword [edi + 0x138]
jb 0x4e2c65
cmp edx, dword [edi + 0x13c]
jae 0x4e2c65
mov eax, dword [edi + 0x134]
mov dword [edx], eax
mov dword [edi + 0x134], edx
jmp 0x4e2c6e
push edx
call fcn.0047cc70
add esp, 4
push 0
push 0x28
mov ecx, edi
call fcn.0047d040
mov esi, eax
add esp, 8
test esi, esi
je 0x4e2c92
push 0x28
push str.cannot_VACUUM_from_within_a_transaction
push esi
call fcn.00572a60
add esp, 0xc
mov dword [ebx], esi
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [edi + 0xac], 1
jle 0x4e2cc2
push str.cannot_VACUUM___SQL_statements_in_progress
call fcn.0047d3e0
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp + 0xc]
mov edx, dword [edi + 0x3c]
mov dword [ebp - 0x14], edx
test esi, esi
je 0x4e2d53
movzx ecx, word [esi + 8]
mov eax, ecx
and eax, 0x3f
cmp byte [eax + 0x619de0], 3
je 0x4e2d02
push str.non_text_filename
mov edx, edi
mov ecx, ebx
call fcn.0047d3e0
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, ecx
and eax, 0x202
cmp eax, 0x202
jne 0x4e2d26
cmp byte [esi + 0xa], 1
jne 0x4e2d26
mov ecx, dword [esi + 0x10]
mov eax, edx
and eax, 0xfffffffe
or eax, 6
mov dword [edi + 0x3c], eax
jmp 0x4e2d58
test cl, 1
je 0x4e2d3a
mov eax, edx
xor ecx, ecx
and eax, 0xfffffffe
or eax, 6
mov dword [edi + 0x3c], eax
jmp 0x4e2d58
mov dl, 1
mov ecx, esi
call fcn.0049b610
mov ecx, eax
mov eax, dword [edi + 0x3c]
and eax, 0xfffffffe
or eax, 6
mov dword [edi + 0x3c], eax
jmp 0x4e2d58
mov ecx, 0x60fec4
mov eax, dword [edi + 0x18]
mov esi, dword [edi + 0x24]
mov edx, dword [edi + 0x20]
mov ebx, dword [edi + 0x64]
mov dword [ebp - 0x24], eax
or eax, 6
mov dword [edi + 0x24], esi
mov dword [edi + 0x18], eax
mov eax, dword [edi + 0x10]
mov dword [ebp - 0x2c], esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x28], edx
and edx, 0xefffaf7f
mov dword [ebp - 0x30], ebx
or edx, 0x201
mov ebx, dword [edi + 0x68]
shl esi, 4
mov dword [edi + 0x20], edx
mov dword [ebp - 0x34], ebx
mov bl, byte [edi + 0x58]
mov byte [edi + 0x58], 0
mov edx, dword [esi + eax]
mov dword [ebp + 8], esi
mov esi, dword [esi + eax + 4]
push ecx
push str.ATTACH__Q_AS_vacuum_db
mov byte [ebp - 2], bl
mov eax, dword [esi + 4]
mov ebx, dword [ebp - 8]
push ebx
push edi
mov eax, dword [eax]
mov dword [ebp - 0x10], edx
mov al, byte [eax + 0xc]
mov byte [ebp - 1], al
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x1c], eax
call fcn.004e2aa0
mov ebx, eax
add esp, 0x10
mov eax, dword [ebp - 0x14]
mov dword [edi + 0x3c], eax
test ebx, ebx
jne 0x4e30e6
mov eax, dword [ebp - 0x1c]
shl eax, 4
add eax, dword [edi + 0x10]
cmp dword [ebp + 0xc], 0
mov dword [ebp - 0x20], eax
mov ebx, dword [eax + 4]
mov dword [ebp - 0xc], ebx
je 0x4e2e4d
mov eax, dword [ebx + 4]
xorps xmm0, xmm0
mov eax, dword [eax]
mov eax, dword [eax + 0x3c]
movlpd qword [ebp - 0x18], xmm0
mov ecx, dword [eax]
test ecx, ecx
je 0x4e2e49
lea edx, [ebp - 0x18]
push edx
push eax
mov eax, dword [ecx + 0x18]
call eax
add esp, 8
test eax, eax
jne 0x4e2e2d
cmp dword [ebp - 0x14], eax
jl 0x4e2e49
jg 0x4e2e2d
cmp dword [ebp - 0x18], eax
jbe 0x4e2e49
mov ecx, dword [ebp - 8]
mov edx, edi
push str.output_file_already_exists
mov ebx, 1
call fcn.0047d3e0
add esp, 4
jmp 0x4e30e6
or dword [edi + 0x18], 8
mov cl, byte [esi + 9]
test cl, cl
je 0x4e2e67
inc dword [esi + 0xc]
cmp byte [esi + 0xa], 0
jne 0x4e2e67
mov ecx, esi
call fcn.0048e570
mov cl, byte [esi + 9]
mov eax, dword [esi + 4]
mov edx, dword [eax + 0x20]
sub edx, dword [eax + 0x24]
mov dword [ebp - 0x14], edx
test cl, cl
je 0x4e2e84
add dword [esi + 0xc], 0xffffffff
jne 0x4e2e84
mov ecx, esi
call fcn.0048e530
mov eax, dword [edi + 0x10]
mov ecx, ebx
mov edx, dword [ebp + 8]
mov edx, dword [edx + eax + 0xc]
mov edx, dword [edx + 0x50]
call fcn.00490af0
xor edx, edx
mov ecx, esi
call fcn.00490b70
mov edx, eax
mov ecx, ebx
call fcn.00490b70
mov edx, 0x21
mov ecx, ebx
call fcn.00490c70
mov edx, dword [ebp - 8]
mov ecx, edi
push str.BEGIN
call fcn.004e29c0
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x4e30e6
xor edx, edx
mov ecx, esi
cmp dword [ebp + 0xc], edx
push eax
mov eax, 2
cmove edx, eax
call fcn.004913f0
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x4e30e6
mov edx, dword [esi + 4]
mov eax, dword [edx]
cmp byte [eax + 5], 5
jne 0x4e2f05
mov dword [edi + 0x5c], ebx
mov edx, dword [esi + 4]
mov ebx, dword [ebp - 0xc]
mov ecx, ebx
mov edx, dword [edx + 0x20]
push 0
push dword [ebp - 0x14]
call fcn.00490d40
add esp, 8
test eax, eax
jne 0x4e30e1
cmp byte [ebp - 1], al
jne 0x4e2f40
mov edx, dword [edi + 0x5c]
mov ecx, ebx
push eax
push dword [ebp - 0x14]
call fcn.00490d40
add esp, 8
test eax, eax
jne 0x4e30e1
cmp byte [edi + 0x51], 0
jne 0x4e30e1
mov al, byte [edi + 0x54]
test al, al
js 0x4e2f56
movsx eax, al
jmp 0x4e2f5d
mov ecx, esi
call fcn.00490f50
mov edx, eax
mov ecx, ebx
call fcn.00490ed0
push dword [ebp - 0x10]
mov eax, dword [ebp - 0x1c]
push str.SELECT_sql_FROM___w_.sqlite_master_WHERE_typetableAND_name__sqlite_sequence_AND_coalesce_rootpage_1__0
push dword [ebp - 8]
mov byte [edi + 0xa4], al
push edi
call fcn.004e2aa0
mov ebx, eax
add esp, 0x10
test ebx, ebx
jne 0x4e30e6
push dword [ebp - 0x10]
push str.SELECT_sql_FROM___w_.sqlite_master_WHERE_typeindex
push dword [ebp - 8]
push edi
call fcn.004e2aa0
mov ebx, eax
add esp, 0x10
test ebx, ebx
jne 0x4e30e6
push dword [ebp - 0x10]
mov byte [edi + 0xa4], al
push str.SELECTINSERT_INTO_vacuum_db.quote_name__SELECTFROM__w_.quote_name_FROM_vacuum_db.sqlite_master_WHERE_typetableAND_coalesce_rootpage_1__0
push dword [ebp - 8]
push edi
call fcn.004e2aa0
and dword [edi + 0x18], 0xfffffffb
mov ebx, eax
add esp, 0x10
test ebx, ebx
jne 0x4e30e6
push dword [ebp - 0x10]
push str.INSERT_INTO_vacuum_db.sqlite_master_SELECTFROM___w_.sqlite_master_WHERE_type_IN_view_trigger__OR_typetableAND_rootpage0_
push dword [ebp - 8]
push edi
call fcn.004e2aa0
mov ebx, eax
add esp, 0x10
test ebx, ebx
jne 0x4e30e6
mov dword [ebp - 0x10], eax
nop dword [eax]
nop dword [eax + eax]
mov cl, byte [esi + 9]
movzx ebx, byte [eax + 0x61571c]
mov eax, dword [esi + 4]
mov dword [ebp - 0x1c], eax
test cl, cl
je 0x4e302a
inc dword [esi + 0xc]
cmp byte [esi + 0xa], 0
jne 0x4e302a
mov ecx, esi
call fcn.0048e570
mov cl, byte [esi + 9]
mov eax, dword [ebp - 0x1c]
cmp ebx, 0xf
jne 0x4e3039
mov eax, dword [eax]
mov ebx, dword [eax + 0x64]
add ebx, dword [esi + 0x14]
jmp 0x4e3045
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 0x38]
mov ebx, dword [eax + ebx*4 + 0x24]
bswap ebx
test cl, cl
je 0x4e3056
add dword [esi + 0xc], 0xffffffff
jne 0x4e3056
mov ecx, esi
call fcn.0048e530
mov ecx, dword [ebp - 0x10]
movzx eax, byte [ecx + 0x61571d]
movzx edx, byte [ecx + 0x61571c]
add eax, ebx
mov ecx, dword [ebp - 0xc]
push eax
call fcn.004983a0
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x4e30e6
mov eax, dword [ebp - 0x10]
add eax, 2
mov dword [ebp - 0x10], eax
cmp eax, 0xa
jl 0x4e3000
cmp dword [ebp + 0xc], ebx
jne 0x4e30a2
mov edx, dword [ebp - 0xc]
mov ecx, esi
call fcn.0049a260
mov ebx, eax
test ebx, ebx
jne 0x4e30e6
mov ecx, dword [ebp - 0xc]
call fcn.004923d0
mov ebx, eax
test ebx, ebx
jne 0x4e30e6
cmp dword [ebp + 0xc], eax
jne 0x4e30e6
mov ebx, dword [ebp - 0xc]
mov ecx, ebx
call fcn.00490f50
mov edx, eax
mov ecx, esi
call fcn.00490ed0
mov eax, dword [ebx + 4]
mov ecx, esi
push 1
push dword [ebp - 0x14]
mov edx, dword [eax + 0x20]
call fcn.00490d40
add esp, 8
mov ebx, eax
jmp 0x4e30e6
mov ebx, 7
mov eax, dword [ebp - 0x24]
or edx, 0xffffffff
mov dword [edi + 0x18], eax
mov ecx, esi
mov eax, dword [ebp - 0x28]
mov dword [edi + 0x20], eax
mov eax, dword [ebp - 0x2c]
mov dword [edi + 0x24], eax
mov eax, dword [ebp - 0x30]
mov dword [edi + 0x64], eax
mov eax, dword [ebp - 0x34]
mov dword [edi + 0x68], eax
mov al, byte [ebp - 2]
push 1
push 0xffffffffffffffff
mov byte [edi + 0xa4], 0
mov byte [edi + 0x58], al
call fcn.00490d40
mov esi, dword [ebp - 0x20]
add esp, 8
mov byte [edi + 0x4f], 1
test esi, esi
je 0x4e3143
mov ecx, dword [esi + 4]
call fcn.00490970
mov dword [esi + 4], 0
mov dword [esi + 0xc], 0
mov ecx, edi
call fcn.004bd450
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret