elide some makeStringAndClear() calls

Change-Id: I4420042f7c8fdf743b888d6f7c1c0d2d3e0b877e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136184
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin 2022-06-20 16:50:29 +02:00
parent 48271742a0
commit 6623d51964
2 changed files with 4 additions and 2 deletions

View file

@ -1898,7 +1898,7 @@ bool INetURLObject::convertRelToAbs(OUString const & rTheRelURIRef,
}
}
INetURLObject aNewURI(aSynAbsURIRef.makeStringAndClear());
INetURLObject aNewURI(aSynAbsURIRef);
if (aNewURI.HasError())
{
// Detect cases where a relative input could not be made absolute

View file

@ -21,6 +21,7 @@
#include <cstddef>
#include <o3tl/string_view.hxx>
#include <tools/debug.hxx>
#include <tools/multisel.hxx>
@ -586,7 +587,8 @@ bool StringRangeEnumerator::setRange( std::u16string_view aNewRange )
aNumberBuf.append( *pInput++ );
if( !aNumberBuf.isEmpty() )
{
sal_Int32 nNumber = aNumberBuf.makeStringAndClear().toInt32() + mnOffset;
sal_Int32 nNumber = o3tl::toInt32(aNumberBuf) + mnOffset;
aNumberBuf.setLength(0);
aNumbers.push_back( nNumber );
bSequence = false;
}