summary refs log tree commit diff
path: root/server.c
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-08-19 14:49:55 -0400
committerJune McEnroe <june@causal.agency>2020-08-19 14:53:53 -0400
commitc03e1e99dc7d4bda710eba0f4fc6716e0c165bd2 (patch)
tree88477f80b8d7a6125ddbe5c4f3b22bb698a5ff70 /server.c
parentAdd Linux support (diff)
downloadscooper-c03e1e99dc7d4bda710eba0f4fc6716e0c165bd2.tar.gz
scooper-c03e1e99dc7d4bda710eba0f4fc6716e0c165bd2.zip
Set a database busy timeout
Diffstat (limited to '')
-rw-r--r--server.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/server.c b/server.c
index 48b760c..6cb0611 100644
--- a/server.c
+++ b/server.c
@@ -110,6 +110,7 @@ int main(int argc, char *argv[]) {
 
 	int error = sqlite3_open_v2(path, &db, SQLITE_OPEN_READONLY, NULL);
 	if (error) errx(EX_NOINPUT, "%s: %s", path, sqlite3_errmsg(db));
+	sqlite3_busy_timeout(db, 1000);
 	atexit(finalizeAll);
 
 	sqlite3_stmt *check;