From: Alexander Butenko Date: Thu, 16 Feb 2012 19:32:41 +0000 (-0400) Subject: Sqlite pragma tuning for formhistory and history X-Git-Url: https://spindle.queued.net/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=69c319d62a6369f5ad6c14111beb76ab4733dd40;p=midori Sqlite pragma tuning for formhistory and history --- diff --git a/extensions/formhistory/formhistory.c b/extensions/formhistory/formhistory.c index 4a3e8dc8..f7a49104 100644 --- a/extensions/formhistory/formhistory.c +++ b/extensions/formhistory/formhistory.c @@ -531,6 +531,10 @@ formhistory_activate_cb (MidoriExtension* extension, "forms (domain text, field text, value text)", NULL, NULL, &errmsg) == SQLITE_OK)) { + sqlite3_exec (db, + /* "PRAGMA synchronous = OFF; PRAGMA temp_store = MEMORY" */ + "PRAGMA count_changes = OFF; PRAGMA journal_mode = TRUNCATE;", + NULL, NULL, &errmsg); priv->db = db; } else diff --git a/midori/main.c b/midori/main.c index 4a92b0e3..e1b53a5f 100644 --- a/midori/main.c +++ b/midori/main.c @@ -441,7 +441,10 @@ midori_history_initialize (KatzeArray* array, return FALSE; } - sqlite3_exec (db, "PRAGMA journal_mode = TRUNCATE;", NULL, NULL, errmsg); + sqlite3_exec (db, + /* "PRAGMA synchronous = OFF; PRAGMA temp_store = MEMORY" */ + "PRAGMA count_changes = OFF; PRAGMA journal_mode = TRUNCATE;", + NULL, NULL, errmsg); if (*errmsg) { g_warning ("Failed to set journal mode: %s", *errmsg);