* update database up-to-date and/or empty checks

This commit is contained in:
Dirk-Jan C. Binnema
2010-01-31 12:14:25 +02:00
parent 143f8c007d
commit 12dc28e3e9
3 changed files with 43 additions and 9 deletions

View File

@ -137,6 +137,11 @@ mu_query_xapian_new (const char* xpath)
return NULL;
}
if (mu_util_xapian_db_is_empty (xpath)) {
g_warning ("database %s is empty; nothing to do", xpath);
return NULL;
}
if (!mu_util_xapian_db_version_up_to_date (xpath)) {
g_warning ("%s is not up-to-date, needs a full update",
xpath);