aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--g10/tofu.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/g10/tofu.c b/g10/tofu.c
index 3f2cd2512..4ad44eb81 100644
--- a/g10/tofu.c
+++ b/g10/tofu.c
@@ -487,6 +487,10 @@ opendb (char *filename, enum db_type type)
db = NULL;
}
+ /* If a DB is locked wait up to 5 seconds for the lock to be cleared
+ before failing. */
+ sqlite3_busy_timeout (db, 5 * 1000);
+
if (filename_free)
xfree (filename);