From 719a2adfbdac8ce26a035e5fedeeaade8706832d Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 8 May 2017 16:12:01 +0200 Subject: remove unnecessary empty OUString fields and vars Change-Id: I940120087a0bc6b1b0abc30a3e7727ce22b7d9a7 Reviewed-on: https://gerrit.libreoffice.org/37394 Tested-by: Jenkins Reviewed-by: Noel Grandin --- dbaccess/source/ext/macromigration/migrationlog.cxx | 8 +++----- dbaccess/source/ext/macromigration/migrationlog.hxx | 3 +-- dbaccess/source/ui/browser/unodatbr.cxx | 5 ++--- 3 files changed, 6 insertions(+), 10 deletions(-) (limited to 'dbaccess/source') diff --git a/dbaccess/source/ext/macromigration/migrationlog.cxx b/dbaccess/source/ext/macromigration/migrationlog.cxx index 4941b4f82a66..b37a9f990124 100644 --- a/dbaccess/source/ext/macromigration/migrationlog.cxx +++ b/dbaccess/source/ext/macromigration/migrationlog.cxx @@ -156,16 +156,14 @@ namespace dbmm // nothing to do here } - const OUString& MigrationLog::getNewLibraryName( DocumentID _nDocID, ScriptType _eScriptType, + OUString MigrationLog::getNewLibraryName( DocumentID _nDocID, ScriptType _eScriptType, const OUString& _rOriginalLibName ) const { - static OUString s_sEmptyString; - DocumentLogs::const_iterator docPos = m_pData->aDocumentLogs.find( _nDocID ); if ( docPos == m_pData->aDocumentLogs.end() ) { OSL_FAIL( "MigrationLog::getNewLibraryName: document is not known!" ); - return s_sEmptyString; + return OUString(); } const DocumentEntry& rDocEntry( docPos->second ); @@ -181,7 +179,7 @@ namespace dbmm } OSL_FAIL( "MigrationLog::getNewLibraryName: doc is known, but library isn't!" ); - return s_sEmptyString; + return OUString(); } namespace diff --git a/dbaccess/source/ext/macromigration/migrationlog.hxx b/dbaccess/source/ext/macromigration/migrationlog.hxx index 85adba176097..d4e757c4c281 100644 --- a/dbaccess/source/ext/macromigration/migrationlog.hxx +++ b/dbaccess/source/ext/macromigration/migrationlog.hxx @@ -83,8 +83,7 @@ namespace dbmm movedLibrary. If not, an assertion will be raised in the non-product builds, and an empty string will be returned. */ - const OUString& - getNewLibraryName( + OUString getNewLibraryName( DocumentID _nDocID, ScriptType _eScriptType, const OUString& _rOriginalLibName diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx index ec132f2eb4df..c57cea8ab205 100644 --- a/dbaccess/source/ui/browser/unodatbr.cxx +++ b/dbaccess/source/ui/browser/unodatbr.cxx @@ -468,9 +468,8 @@ void SbaTableQueryBrowser::impl_sanitizeRowSetClauses_nothrow() if ( invalidColumn ) { // reset the complete order statement at both the row set and the parser - const OUString sEmptyOrder; - xRowSetProps->setPropertyValue( PROPERTY_ORDER, makeAny( sEmptyOrder ) ); - xComposer->setOrder( sEmptyOrder ); + xRowSetProps->setPropertyValue( PROPERTY_ORDER, makeAny( OUString() ) ); + xComposer->setOrder( "" ); } // check if the columns participating in the filter refer to existing tables -- cgit