From 68875ba600c635f985aa8deea7f940816a5e7645 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 9 Sep 2011 23:28:27 +0200 Subject: database: return GError on failure --- src/update.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/update.c') diff --git a/src/update.c b/src/update.c index 8fe6023ae..1a3060653 100644 --- a/src/update.c +++ b/src/update.c @@ -68,8 +68,14 @@ static void * update_task(void *_path) modified = update_walk(path, discard); - if (modified || !db_exists()) - db_save(); + if (modified || !db_exists()) { + GError *error = NULL; + if (!db_save(&error)) { + g_warning("Failed to save database: %s", + error->message); + g_error_free(error); + } + } if (path != NULL && *path != 0) g_debug("finished: %s", path); -- cgit v1.2.3