Function at 0x5014b0
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push esi
mov esi, dword [ebp + 0xc]
push edi
mov dword [ebp - 0x24], 0
cmp byte [esi + 0x4f], 0
jne 0x50150b
mov edi, dword [ebp + 8]
mov eax, dword [edi]
test eax, eax
je 0x5014db
push eax
push esi
call fcn.004e9ef0
add esp, 8
push 0
push 0x28
push esi
call fcn.004e9f60
mov esi, eax
add esp, 0xc
test esi, esi
je 0x5014fe
push 0x28
push str.cannot_VACUUM_from_within_a_transaction
push esi
call sub.msvcrt.dll_memcpy
add esp, 0xc
mov dword [edi], esi
mov eax, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0xb0], 1
jle 0x501543
mov edi, dword [ebp + 8]
mov eax, dword [edi]
test eax, eax
je 0x501527
push eax
push esi
call fcn.004e9ef0
add esp, 8
push 0
push 0x2b
push esi
call fcn.004e9f60
mov esi, eax
add esp, 0xc
test esi, esi
je 0x5014fe
push 0x2b
push str.cannot_VACUUM___SQL_statements_in_progress
jmp 0x5014f5
mov ecx, dword [ebp + 0x14]
mov eax, dword [esi + 0x3c]
mov dword [ebp - 0x14], eax
test ecx, ecx
je 0x5015bf
movzx eax, word [ecx + 8]
and eax, 0x3f
cmp byte [eax + 0x584890], 3
je 0x5015a6
mov edi, dword [ebp + 8]
mov eax, dword [edi]
test eax, eax
je 0x501573
push eax
push esi
call fcn.004e9ef0
add esp, 8
push 0
push 0x12
push esi
call fcn.004e9f60
add esp, 0xc
test eax, eax
je 0x501599
movups xmm0, xmmword [str.non_text_filename]
movups xmmword [eax], xmm0
mov cx, word [0x58cfcc]
mov word [eax + 0x10], cx
mov dword [edi], eax
mov eax, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push ecx
call fcn.004b1cd0
mov ecx, dword [esi + 0x3c]
add esp, 4
and ecx, 0xfffffffe
mov edx, eax
or ecx, 6
mov dword [esi + 0x3c], ecx
jmp 0x5015c4
mov edx, 0x597747
mov ecx, dword [esi + 0x20]
mov eax, dword [esi + 0x18]
push ebx
mov ebx, dword [esi + 0x24]
mov dword [ebp - 0x20], ecx
mov cl, byte [esi + 0x58]
mov edi, dword [esi + 0x64]
mov dword [ebp - 0x28], eax
or eax, 6
mov dword [ebp - 0x2c], ebx
and ebx, 0xfffffffe
mov dword [esi + 0x24], ebx
mov ebx, dword [ebp + 0x10]
mov byte [ebp - 1], cl
mov ecx, dword [ebp - 0x20]
mov dword [esi + 0x18], eax
and ecx, 0xefffafff
mov eax, dword [esi + 0x10]
or ecx, 0x201
mov dword [esi + 0x20], ecx
shl ebx, 4
mov byte [esi + 0x58], 0
mov dword [ebp + 0x10], ebx
push edx
mov ecx, dword [eax + ebx]
mov ebx, dword [eax + ebx + 4]
mov dword [ebp - 0xc], ecx
mov ecx, dword [ebp + 8]
push str.ATTACH__Q_AS_vacuum_db
mov eax, dword [ebx + 4]
push ecx
mov dword [ebp - 0x30], edi
mov edi, dword [esi + 0x68]
mov eax, dword [eax]
push esi
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x10], ebx
mov al, byte [eax + 0xc]
mov byte [ebp + 0xf], al
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x1c], eax
call fcn.004c95e0
mov edi, eax
add esp, 0x10
mov eax, dword [ebp - 0x14]
mov dword [esi + 0x3c], eax
test edi, edi
jne 0x501933
mov eax, dword [ebp - 0x1c]
shl eax, 4
add eax, dword [esi + 0x10]
cmp dword [ebp + 0x14], 0
mov dword [ebp - 0x24], eax
mov edi, dword [eax + 4]
mov dword [ebp - 8], edi
je 0x5016f4
mov eax, dword [edi + 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 0x5016f0
lea edx, [ebp - 0x18]
push edx
push eax
mov eax, dword [ecx + 0x18]
call eax
add esp, 8
test eax, eax
jne 0x5016a7
cmp dword [ebp - 0x14], eax
jl 0x5016f0
jg 0x5016a7
cmp dword [ebp - 0x18], eax
jbe 0x5016f0
mov eax, dword [ebp + 8]
mov edi, 1
mov eax, dword [eax]
test eax, eax
je 0x5016bf
push eax
push esi
call fcn.004e9ef0
add esp, 8
push 0
push 0x1b
push esi
call fcn.004e9f60
add esp, 0xc
mov dword [ebp + 0xc], eax
test eax, eax
je 0x5016e6
push 0x1b
push str.output_file_already_exists
push eax
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp + 0xc]
add esp, 0xc
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
jmp 0x501933
or dword [esi + 0x18], 8
mov cl, byte [ebx + 9]
test cl, cl
je 0x501710
inc dword [ebx + 0xc]
cmp byte [ebx + 0xa], 0
jne 0x501710
push ebx
call fcn.004c2580
mov cl, byte [ebx + 9]
add esp, 4
mov eax, dword [ebx + 4]
mov edx, dword [eax + 0x20]
sub edx, dword [eax + 0x24]
mov dword [ebp - 0x14], edx
test cl, cl
je 0x50172f
add dword [ebx + 0xc], 0xffffffff
jne 0x50172f
push ebx
call fcn.0051e740
add esp, 4
mov eax, dword [esi + 0x10]
mov ecx, dword [ebp + 0x10]
mov eax, dword [eax + ecx + 0xc]
push dword [eax + 0x50]
push edi
call fcn.004e6670
push 0
push ebx
call fcn.004e68a0
push eax
push edi
call fcn.004e68a0
push 0x21
push edi
call fcn.004e67d0
push str.BEGIN
push dword [ebp + 8]
push esi
call fcn.004c9510
mov edi, eax
add esp, 0x2c
test edi, edi
jne 0x501933
cmp dword [ebp + 0x14], eax
mov ecx, 2
push eax
cmove eax, ecx
push eax
push ebx
call fcn.004e3d00
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x501933
mov ecx, dword [ebx + 4]
mov eax, dword [ecx]
cmp byte [eax + 5], 5
jne 0x5017a5
mov dword [esi + 0x5c], edi
mov ecx, dword [ebx + 4]
mov edi, dword [ebp - 8]
push 0
push dword [ebp - 0x14]
push dword [ecx + 0x20]
push edi
call fcn.004e6700
add esp, 0x10
test eax, eax
jne 0x501929
cmp byte [ebp + 0xf], al
jne 0x5017de
push eax
push dword [ebp - 0x14]
push dword [esi + 0x5c]
push edi
call fcn.004e6700
add esp, 0x10
test eax, eax
jne 0x501929
cmp byte [esi + 0x51], 0
jne 0x501929
mov al, byte [esi + 0x54]
test al, al
js 0x5017f4
movsx eax, al
jmp 0x5017fd
push ebx
call fcn.004e4c00
add esp, 4
push eax
push edi
call fcn.004e65f0
push dword [ebp - 0xc]
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 [esi + 0xa4], al
push esi
call fcn.004c95e0
mov edi, eax
add esp, 0x18
test edi, edi
jne 0x501933
push dword [ebp - 0xc]
push str.SELECT_sql_FROM___w_.sqlite_master_WHERE_typeindex
push dword [ebp + 8]
push esi
call fcn.004c95e0
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x501933
push dword [ebp - 0xc]
mov byte [esi + 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 esi
call fcn.004c95e0
and dword [esi + 0x18], 0xfffffffb
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x501933
push dword [ebp - 0xc]
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 esi
call fcn.004c95e0
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x501933
xor ebx, ebx
lea eax, [ebp + 0xc]
push eax
movzx eax, byte [ebx + 0x584988]
push eax
push dword [ebp - 0x10]
call fcn.004e4c70
movzx eax, byte [ebx + 0x584989]
add eax, dword [ebp + 0xc]
push eax
movzx eax, byte [ebx + 0x584988]
push eax
push dword [ebp - 8]
call fcn.004e6b40
mov edi, eax
add esp, 0x18
test edi, edi
jne 0x501930
add ebx, 2
cmp ebx, 0xa
jl 0x501891
mov ebx, dword [ebp - 0x10]
cmp dword [ebp + 0x14], eax
jne 0x5018eb
push dword [ebp - 8]
push ebx
call fcn.004e4500
mov edi, eax
add esp, 8
test edi, edi
jne 0x501933
push dword [ebp - 8]
call fcn.004e4320
mov edi, eax
add esp, 4
test edi, edi
jne 0x501933
cmp dword [ebp + 0x14], eax
jne 0x501933
mov edi, dword [ebp - 8]
push edi
call fcn.004e4c00
push eax
push ebx
call fcn.004e65f0
mov eax, dword [edi + 4]
push 1
push dword [ebp - 0x14]
push dword [eax + 0x20]
push ebx
call fcn.004e6700
add esp, 0x1c
mov edi, eax
jmp 0x501933
mov edi, 7
jmp 0x501933
mov ebx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x28]
mov dword [esi + 0x18], eax
mov eax, dword [ebp - 0x20]
mov dword [esi + 0x20], eax
mov eax, dword [ebp - 0x2c]
mov dword [esi + 0x24], eax
mov eax, dword [ebp - 0x30]
push 1
mov dword [esi + 0x64], eax
mov eax, dword [ebp - 0x34]
push 0xffffffffffffffff
mov dword [esi + 0x68], eax
mov al, byte [ebp - 1]
push 0xffffffffffffffff
push ebx
mov byte [esi + 0xa4], 0
mov byte [esi + 0x58], al
call fcn.004e6700
mov ebx, dword [ebp - 0x24]
add esp, 0x10
mov byte [esi + 0x4f], 1
test ebx, ebx
je 0x501991
push dword [ebx + 4]
call fcn.004e40c0
add esp, 4
mov dword [ebx + 4], 0
mov dword [ebx + 0xc], 0
push esi
call fcn.005003f0
add esp, 4
mov eax, edi
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret