Index: backends/flint/flint_database.cc
===================================================================
--- backends/flint/flint_database.cc	(revision 8981)
+++ backends/flint/flint_database.cc	(working copy)
@@ -761,6 +786,8 @@
 
 	// Remove the new doclength.
 	doclens.erase(did);
+    } catch (Xapian::DocNotFoundError &) {
+	throw;
     } catch (...) {
 	// If an error occurs while deleting a document, or doing any other
 	// transaction, the modifications so far must be cleared before

