compact: catch Xapian::Error consistently