From 09ec9690452b752e36b01730032f13c9074ed2f1 Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Mon, 22 Sep 2008 21:14:31 +0100 Subject: [PATCH] bugfix: turn off synchronous fsync when using PkExtra as the data isn't valuable, and we can reduce the time of the desktop scanning by 80% --- libpackagekit/pk-extra.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libpackagekit/pk-extra.c b/libpackagekit/pk-extra.c index f365749ca..904d5f1ba 100644 --- a/libpackagekit/pk-extra.c +++ b/libpackagekit/pk-extra.c @@ -664,6 +664,9 @@ pk_extra_set_database (PkExtra *extra, const gchar *filename) } } + /* we don't need to keep syncing */ + sqlite3_exec (extra->priv->db, "PRAGMA synchronous=OFF", NULL, NULL, NULL); + /* try to populate a working cache */ if (extra->priv->access == PK_EXTRA_ACCESS_READ_ONLY || extra->priv->access == PK_EXTRA_ACCESS_READ_WRITE)