[Libreoffice-commits] core.git: comphelper/source
Kohei Yoshida
kohei.yoshida at collabora.com
Wed Jul 9 09:15:50 PDT 2014
comphelper/source/misc/storagehelper.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit f8226e87b446d96a3803df46d9b786c233d1e1f5
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date: Wed Jul 9 12:04:35 2014 -0400
Pass a useful exception message.
Change-Id: Idde024a7b6896571d159c3983ef1985fa12d0c5a
diff --git a/comphelper/source/misc/storagehelper.cxx b/comphelper/source/misc/storagehelper.cxx
index 0c60a7c..51ee8c5 100644
--- a/comphelper/source/misc/storagehelper.cxx
+++ b/comphelper/source/misc/storagehelper.cxx
@@ -45,6 +45,7 @@
#include <comphelper/storagehelper.hxx>
+#include <boost/current_function.hpp>
using namespace ::com::sun::star;
@@ -274,7 +275,13 @@ sal_Int32 OStorageHelper::GetXStorageFormat(
else
{
// the mediatype is not known
- throw beans::IllegalTypeException();
+ OUString aMsg(BOOST_CURRENT_FUNCTION);
+ aMsg += ":";
+ aMsg += OUString::number(__LINE__);
+ aMsg += ": unknown media type '";
+ aMsg += aMediaType;
+ aMsg += "'";
+ throw beans::IllegalTypeException(aMsg);
}
return nResult;
More information about the Libreoffice-commits
mailing list