1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-01 00:19:27 +02:00

Merge pull request from lmarz/dbpage_fix

ProjectFileIO: Check for SQLITE_ENABLE_DBPAGE_VTAB option

Signed-off-by: Emily Mabrey <emabrey@tenacityaudio.org>
Reference-to: https://github.com/tenacityteam/tenacity/pull/568
This commit is contained in:
Emily Mabrey 2021-09-05 01:56:50 -04:00 committed by GitHub
commit b9ad2747fb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2389,6 +2389,12 @@ int64_t ProjectFileIO::GetDiskUsage(DBConnection &conn, SampleBlockID blockid /*
int64_t right = 0;
int rc;
// "sqlite_dbpage" is a compile-time defined option
if(!sqlite3_compileoption_used("SQLITE_ENABLE_DBPAGE_VTAB"))
{
return 0;
}
// Get the rootpage for the sampleblocks table.
sqlite3_stmt *stmt =
conn.Prepare(DBConnection::GetRootPage,