mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-11-10 23:13:48 +01:00
Set database version on initialization
This commit is contained in:
parent
806fa70a7c
commit
5a5316ca61
@ -265,8 +265,11 @@ sqlite_db_check_layout(sqlite3* session, const int database_version, const bool
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (new_db == true)
|
||||
if (new_db == true) {
|
||||
/* set version if initializing a new database */
|
||||
sqlite3_exec(session, "PRAGMA user_version = " G_STRINGIFY(DATABASE_VERSION) ";", NULL, 0, NULL);
|
||||
return;
|
||||
}
|
||||
|
||||
#ifndef SQLITE_OMIT_COMPILEOPTION_DIAGS
|
||||
if (sqlite3_compileoption_used("SQLITE_OMIT_ALTERTABLE") == 1) {
|
||||
|
Loading…
Reference in New Issue
Block a user