summaryrefslogtreecommitdiff
path: root/uui
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-06-27 14:06:27 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-06-28 08:55:10 +0200
commit26c82e22bf4f077022ae88d0a7f8ad0fa6d2a5ba (patch)
tree42bf27db4a1da0fa3ea3bdd7997e7058c1638f98 /uui
parentef531e85d95fe18d553bce1a6926d24c08ffe2bf (diff)
loplugin:oncevar in ucb..vbahelper
Change-Id: I1fc7c7505a42b3bf9d4a5ab22961930b9831d4ae Reviewed-on: https://gerrit.libreoffice.org/39327 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'uui')
-rw-r--r--uui/source/iahndl.cxx15
-rw-r--r--uui/source/secmacrowarnings.cxx4
2 files changed, 6 insertions, 13 deletions
diff --git a/uui/source/iahndl.cxx b/uui/source/iahndl.cxx
index 6febfae49664..0d742684bb73 100644
--- a/uui/source/iahndl.cxx
+++ b/uui/source/iahndl.cxx
@@ -403,7 +403,6 @@ UUIInteractionHelper::handleRequest_impl(
script::ModuleSizeExceededRequest aModSizeException;
if (aAnyRequest >>= aModSizeException )
{
- ErrCode nErrorCode = ERRCODE_UUI_IO_MODULESIZEEXCEEDED;
std::vector< OUString > aArguments;
uno::Sequence< OUString > sModules
= aModSizeException.Names;
@@ -420,7 +419,7 @@ UUIInteractionHelper::handleRequest_impl(
aArguments.push_back( aName );
}
handleErrorHandlerRequest( task::InteractionClassification_WARNING,
- nErrorCode,
+ ERRCODE_UUI_IO_MODULESIZEEXCEEDED,
aArguments,
rRequest->getContinuations(),
bObtainErrorStringOnly,
@@ -454,7 +453,6 @@ UUIInteractionHelper::handleRequest_impl(
ucb::UnsupportedNameClashException aUORequest;
if (aAnyRequest >>= aUORequest)
{
- ErrCode nErrorCode = ERRCODE_UUI_IO_UNSUPPORTEDOVERWRITE;
std::vector< OUString > aArguments;
uno::Reference< task::XInteractionApprove > xApprove;
@@ -465,7 +463,7 @@ UUIInteractionHelper::handleRequest_impl(
if ( xApprove.is() && xDisapprove.is() )
{
handleErrorHandlerRequest( task::InteractionClassification_QUERY,
- nErrorCode,
+ ERRCODE_UUI_IO_UNSUPPORTEDOVERWRITE,
aArguments,
rRequest->getContinuations(),
bObtainErrorStringOnly,
@@ -675,12 +673,11 @@ UUIInteractionHelper::handleRequest_impl(
ucb::InteractiveLockingNotLockedException aLNLException;
if (aAnyRequest >>= aLNLException)
{
- ErrCode nErrorCode = ERRCODE_UUI_LOCKING_NOT_LOCKED;
std::vector< OUString > aArguments;
aArguments.push_back( aLNLException.Url );
handleErrorHandlerRequest( aLNLException.Classification,
- nErrorCode,
+ ERRCODE_UUI_LOCKING_NOT_LOCKED,
aArguments,
rRequest->getContinuations(),
bObtainErrorStringOnly,
@@ -692,12 +689,11 @@ UUIInteractionHelper::handleRequest_impl(
ucb::InteractiveLockingLockExpiredException aLLEException;
if (aAnyRequest >>= aLLEException)
{
- ErrCode nErrorCode = ERRCODE_UUI_LOCKING_LOCK_EXPIRED;
std::vector< OUString > aArguments;
aArguments.push_back( aLLEException.Url );
handleErrorHandlerRequest( aLLEException.Classification,
- nErrorCode,
+ ERRCODE_UUI_LOCKING_LOCK_EXPIRED,
aArguments,
rRequest->getContinuations(),
bObtainErrorStringOnly,
@@ -747,12 +743,11 @@ UUIInteractionHelper::handleRequest_impl(
loader::CannotActivateFactoryException aCannotActivateFactoryException;
if (aAnyRequest >>= aCannotActivateFactoryException)
{
- ErrCode nErrorCode = ERRCODE_UUI_CANNOT_ACTIVATE_FACTORY;
std::vector< OUString > aArguments;
aArguments.push_back( aCannotActivateFactoryException.Message );
handleErrorHandlerRequest( task::InteractionClassification_ERROR,
- nErrorCode,
+ ERRCODE_UUI_CANNOT_ACTIVATE_FACTORY,
aArguments,
rRequest->getContinuations(),
bObtainErrorStringOnly,
diff --git a/uui/source/secmacrowarnings.cxx b/uui/source/secmacrowarnings.cxx
index 04fb3a6b0b0a..47b8bdd58a14 100644
--- a/uui/source/secmacrowarnings.cxx
+++ b/uui/source/secmacrowarnings.cxx
@@ -229,9 +229,7 @@ void MacroWarning::SetCertificate( const css::uno::Reference< css::security::XCe
mxCert = _rxCert;
if( mxCert.is() )
{
- OUString aCN_Id("CN");
- OUString s;
- s = GetContentPart( mxCert->getSubjectName(), aCN_Id );
+ OUString s = GetContentPart( mxCert->getSubjectName(), "CN" );
mpSignsFI->SetText( s );
mpViewSignsBtn->Enable();
}