summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-02-03 14:02:22 +0100
committerMichael Stahl <mstahl@redhat.com>2016-02-03 14:22:48 +0100
commit4a2824e72aae407f5f2a86e6ef45278ef864d437 (patch)
tree22aad7b69924d455ca77d9615b2192a7759e7545
parent1e619fdf9e79cb49895d83fe7f5a1f373495b915 (diff)
starmath: tdf#97190: don't assert on missing base URL
There are valid scenarios where we don't have a URL at all, such as when importing MathML from the clipboard. Also there probably isn't much of a problem caused by missing base URLs in Math anyway since RDF import is currently not implemented and i'm not sure if hyperlinks in Math documents are possible at all. Change-Id: I13b70ac62542364f329875e292c574883255af5e
-rw-r--r--starmath/source/mathmlimport.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/starmath/source/mathmlimport.cxx b/starmath/source/mathmlimport.cxx
index ca557ae94748..36884c9d6405 100644
--- a/starmath/source/mathmlimport.cxx
+++ b/starmath/source/mathmlimport.cxx
@@ -142,7 +142,9 @@ sal_uLong SmXMLImportWrapper::Import(SfxMedium &rMedium)
// Set base URI
OUString const baseURI(rMedium.GetBaseURL());
- assert(!baseURI.isEmpty()); // needed for relative URLs
+ // needed for relative URLs; but it's OK to import e.g. MathML from the
+ // clipboard without one
+ SAL_INFO_IF(baseURI.isEmpty(), "starmath", "SmXMLImportWrapper: no base URL");
xInfoSet->setPropertyValue("BaseURI", makeAny(baseURI));
sal_Int32 nSteps=3;