summaryrefslogtreecommitdiff
path: root/helpcompiler
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-03-14 12:50:39 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-03-14 17:50:11 +0000
commit899dfbca1755f730dc935ca0d929236f999b9879 (patch)
tree1bd455232191f057c088791145f0d1fb8329ce9d /helpcompiler
parente056c1ce10779b42ae17866913cf4db06b86a491 (diff)
elide some temporary OStrings
where we can pass a string_view into OStringToOUString Change-Id: If7803ba49aa15f6e9c7bd386d32fb84003155390 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148844 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'helpcompiler')
-rw-r--r--helpcompiler/source/HelpLinker.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/helpcompiler/source/HelpLinker.cxx b/helpcompiler/source/HelpLinker.cxx
index e95b9168bf17..708f12a64114 100644
--- a/helpcompiler/source/HelpLinker.cxx
+++ b/helpcompiler/source/HelpLinker.cxx
@@ -71,7 +71,7 @@ IndexerPreProcessor::~IndexerPreProcessor()
static std::string getEncodedPath( const std::string& Path )
{
- OString aOStr_Path( Path.c_str() );
+ std::string_view aOStr_Path( Path.c_str() );
OUString aOUStr_Path( OStringToOUString
( aOStr_Path, osl_getThreadTextEncoding() ) );
OUString aPathURL;
@@ -834,9 +834,9 @@ static void StructuredXMLErrorFunction(SAL_UNUSED_PARAMETER void *, xmlErrorPtr
HelpProcessingErrorInfo& HelpProcessingErrorInfo::operator=( const struct HelpProcessingException& e )
{
m_eErrorClass = e.m_eErrorClass;
- OString tmpErrorMsg( e.m_aErrorMsg.c_str() );
+ std::string_view tmpErrorMsg( e.m_aErrorMsg.c_str() );
m_aErrorMsg = OStringToOUString( tmpErrorMsg, osl_getThreadTextEncoding() );
- OString tmpXMLParsingFile( e.m_aXMLParsingFile.c_str() );
+ std::string_view tmpXMLParsingFile( e.m_aXMLParsingFile.c_str() );
m_aXMLParsingFile = OStringToOUString( tmpXMLParsingFile, osl_getThreadTextEncoding() );
m_nXMLParsingLine = e.m_nXMLParsingLine;
return *this;