* mu-util: improve xapian exception error logging

This commit is contained in:
Dirk-Jan C. Binnema
2010-01-07 08:42:01 +02:00
parent adfdfe230d
commit 3e81be3c1e

View File

@ -80,9 +80,8 @@ gboolean mu_util_check_dir (const gchar* path, gboolean readable,
*/ */
#define MU_XAPIAN_CATCH_BLOCK \ #define MU_XAPIAN_CATCH_BLOCK \
catch (const Xapian::Error &err) { \ catch (const Xapian::Error &err) { \
g_warning ("%s: caught xapian exception '%s' (%s)", \ g_warning ("%s: caught xapian exception '%s'", \
__FUNCTION__, err.get_msg().c_str(), \ __FUNCTION__, err.get_msg().c_str()); \
err.get_error_string()); \
} catch (...) { \ } catch (...) { \
g_warning ("%s: caught exception", __FUNCTION__); \ g_warning ("%s: caught exception", __FUNCTION__); \
} }
@ -90,9 +89,8 @@ gboolean mu_util_check_dir (const gchar* path, gboolean readable,
#define MU_XAPIAN_CATCH_BLOCK_RETURN(R) \ #define MU_XAPIAN_CATCH_BLOCK_RETURN(R) \
catch (const Xapian::Error &err) { \ catch (const Xapian::Error &err) { \
g_warning ("%s: caught xapian exception '%s' (%s)", \ g_warning ("%s: caught xapian exception '%s'", \
__FUNCTION__, err.get_msg().c_str(), \ __FUNCTION__, err.get_msg().c_str()); \
err.get_error_string()); \
return (R); \ return (R); \
} catch (...) { \ } catch (...) { \
g_warning ("%s: caught exception", __FUNCTION__); \ g_warning ("%s: caught exception", __FUNCTION__); \