Kaydet (Commit) 83d8ccfb authored tarafından Michael Stahl's avatar Michael Stahl

xmloff: convert to assert in SvXMLMetaExport

Change-Id: Ib959da6f4dab0b290955e8b786d6efeef7f307b0
üst 068f16e2
...@@ -286,7 +286,7 @@ void SvXMLMetaExport::_MExport() ...@@ -286,7 +286,7 @@ void SvXMLMetaExport::_MExport()
XML_NAMESPACE_META, XML_CELL_COUNT, aValue ); XML_NAMESPACE_META, XML_CELL_COUNT, aValue );
else else
{ {
DBG_ASSERT( false, "Unknown statistic value!\n" ); SAL_WARN("xmloff", "Unknown statistic value!");
} }
} }
} }
...@@ -308,7 +308,7 @@ SvXMLMetaExport::SvXMLMetaExport( ...@@ -308,7 +308,7 @@ SvXMLMetaExport::SvXMLMetaExport(
m_level( 0 ), m_level( 0 ),
m_preservedNSs() m_preservedNSs()
{ {
DBG_ASSERT( mxDocProps.is(), "no document properties" ); assert(mxDocProps.is());
} }
SvXMLMetaExport::~SvXMLMetaExport() SvXMLMetaExport::~SvXMLMetaExport()
...@@ -331,7 +331,7 @@ void SvXMLMetaExport::Export() ...@@ -331,7 +331,7 @@ void SvXMLMetaExport::Export()
} else if (attrname.equalsAsciiL(s_xmlns, strlen(s_xmlns))) { } else if (attrname.equalsAsciiL(s_xmlns, strlen(s_xmlns))) {
// default initialized empty string // default initialized empty string
} else { } else {
OSL_FAIL("namespace attribute not starting with xmlns unexpected"); assert(!"namespace attribute not starting with xmlns unexpected");
} }
ns.Second = rNsMap.GetNameByKey(key); ns.Second = rNsMap.GetNameByKey(key);
namespaces.push_back(ns); namespaces.push_back(ns);
...@@ -352,7 +352,7 @@ SvXMLMetaExport::startDocument() ...@@ -352,7 +352,7 @@ SvXMLMetaExport::startDocument()
throw (uno::RuntimeException, xml::sax::SAXException, std::exception) throw (uno::RuntimeException, xml::sax::SAXException, std::exception)
{ {
// ignore: has already been done by SvXMLExport::exportDoc // ignore: has already been done by SvXMLExport::exportDoc
DBG_ASSERT( m_level == 0, "SvXMLMetaExport: level error" ); assert(m_level == 0 && "SvXMLMetaExport: level error");
} }
void SAL_CALL void SAL_CALL
...@@ -360,7 +360,7 @@ SvXMLMetaExport::endDocument() ...@@ -360,7 +360,7 @@ SvXMLMetaExport::endDocument()
throw (uno::RuntimeException, xml::sax::SAXException, std::exception) throw (uno::RuntimeException, xml::sax::SAXException, std::exception)
{ {
// ignore: will be done by SvXMLExport::exportDoc // ignore: will be done by SvXMLExport::exportDoc
DBG_ASSERT( m_level == 0, "SvXMLMetaExport: level error" ); assert(m_level == 0 && "SvXMLMetaExport: level error");
} }
// unfortunately, this method contains far too much ugly namespace mangling. // unfortunately, this method contains far too much ugly namespace mangling.
...@@ -456,7 +456,7 @@ SvXMLMetaExport::endElement(const OUString & i_rName) ...@@ -456,7 +456,7 @@ SvXMLMetaExport::endElement(const OUString & i_rName)
// ignore the root; see startElement // ignore the root; see startElement
return; return;
} }
DBG_ASSERT( m_level >= 0, "SvXMLMetaExport: level error" ); assert(m_level >= 0 && "SvXMLMetaExport: level error");
mrExport.EndElement(i_rName, false); mrExport.EndElement(i_rName, false);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment