fdo#43460 unoxml,writerfilter,xmlsecurity: use isEmpty()
Change-Id: Iba3b39086212803bc41384f5c8f51e42712a5249 Reviewed-on: https://gerrit.libreoffice.org/4349 Reviewed-by: Noel Power <noel.power@suse.com> Tested-by: Noel Power <noel.power@suse.com>
This commit is contained in:
committed by
Noel Power
parent
ad09b2f7ef
commit
b5f3f55ce5
@@ -502,7 +502,7 @@ namespace DOM
|
|||||||
Reference< XAttr > aAttr;
|
Reference< XAttr > aAttr;
|
||||||
if (!oldAttr->getNamespaceURI().isEmpty()) {
|
if (!oldAttr->getNamespaceURI().isEmpty()) {
|
||||||
OUStringBuffer qname(oldAttr->getPrefix());
|
OUStringBuffer qname(oldAttr->getPrefix());
|
||||||
if (0 != qname.getLength()) {
|
if (!qname.isEmpty()) {
|
||||||
qname.append(sal_Unicode(':'));
|
qname.append(sal_Unicode(':'));
|
||||||
}
|
}
|
||||||
qname.append(oldAttr->getName());
|
qname.append(oldAttr->getName());
|
||||||
|
@@ -1237,7 +1237,7 @@ int RTFDocumentImpl::dispatchDestination(RTFKeyword nKeyword)
|
|||||||
aBuf.append(ch);
|
aBuf.append(ch);
|
||||||
else if (bInKeyword && isspace(ch))
|
else if (bInKeyword && isspace(ch))
|
||||||
bInKeyword = false;
|
bInKeyword = false;
|
||||||
if (aBuf.getLength() > 0 && !isalnum(ch))
|
if (!aBuf.isEmpty() && !isalnum(ch))
|
||||||
bFoundCode = true;
|
bFoundCode = true;
|
||||||
}
|
}
|
||||||
Strm().Seek(nPos);
|
Strm().Seek(nPos);
|
||||||
@@ -4649,12 +4649,12 @@ void RTFDocumentImpl::setSkipUnknown(bool bSkipUnknown)
|
|||||||
|
|
||||||
void RTFDocumentImpl::checkUnicode(bool bUnicode, bool bHex)
|
void RTFDocumentImpl::checkUnicode(bool bUnicode, bool bHex)
|
||||||
{
|
{
|
||||||
if (bUnicode && m_aUnicodeBuffer.getLength() > 0)
|
if (bUnicode && !m_aUnicodeBuffer.isEmpty())
|
||||||
{
|
{
|
||||||
OUString aString = m_aUnicodeBuffer.makeStringAndClear();
|
OUString aString = m_aUnicodeBuffer.makeStringAndClear();
|
||||||
text(aString);
|
text(aString);
|
||||||
}
|
}
|
||||||
if (bHex && m_aHexBuffer.getLength() > 0)
|
if (bHex && !m_aHexBuffer.isEmpty())
|
||||||
{
|
{
|
||||||
OUString aString = OStringToOUString(m_aHexBuffer.makeStringAndClear(), m_aStates.top().nCurrentEncoding);
|
OUString aString = OStringToOUString(m_aHexBuffer.makeStringAndClear(), m_aStates.top().nCurrentEncoding);
|
||||||
text(aString);
|
text(aString);
|
||||||
|
@@ -284,7 +284,7 @@ vector< pair< OUString, OUString> > parseDN(const OUString& rRawString)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (sbufValue.getLength())
|
if (!sbufValue.isEmpty())
|
||||||
{
|
{
|
||||||
OSL_ASSERT(!sType.isEmpty());
|
OSL_ASSERT(!sType.isEmpty());
|
||||||
retVal.push_back(make_pair(sType, sbufValue.makeStringAndClear()));
|
retVal.push_back(make_pair(sType, sbufValue.makeStringAndClear()));
|
||||||
|
Reference in New Issue
Block a user