summaryrefslogtreecommitdiff
path: root/xmlsecurity
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-03-17 09:18:44 +0200
committerNoel Grandin <noel@peralex.com>2014-03-17 13:30:53 +0200
commit4386863e1a5b3aebaded5ff66e4bd29ca7ce67d0 (patch)
tree994eba6f93140a48fa6ff6d822b9db53b77eb8b9 /xmlsecurity
parent676558732b8f77460fd91955f739e4ccc5eb8111 (diff)
xmlsecurity: prefer passing OUString by reference
Change-Id: I44b96a8adc2f6309088d99ff3bce438f660d302d
Diffstat (limited to 'xmlsecurity')
-rw-r--r--xmlsecurity/inc/xmlsecurity/biginteger.hxx2
-rw-r--r--xmlsecurity/inc/xmlsecurity/documentsignaturehelper.hxx2
-rw-r--r--xmlsecurity/inc/xmlsecurity/sigstruct.hxx4
-rw-r--r--xmlsecurity/inc/xmlsecurity/xmlsignaturehelper.hxx2
-rw-r--r--xmlsecurity/source/component/documentdigitalsignatures.cxx2
-rw-r--r--xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx4
-rw-r--r--xmlsecurity/source/helper/documentsignaturehelper.cxx4
-rw-r--r--xmlsecurity/source/helper/xmlsignaturehelper.cxx2
-rw-r--r--xmlsecurity/source/helper/xsecctl.hxx2
-rw-r--r--xmlsecurity/source/xmlsec/biginteger.cxx2
10 files changed, 13 insertions, 13 deletions
diff --git a/xmlsecurity/inc/xmlsecurity/biginteger.hxx b/xmlsecurity/inc/xmlsecurity/biginteger.hxx
index f7c3c6124a63..32e774404a78 100644
--- a/xmlsecurity/inc/xmlsecurity/biginteger.hxx
+++ b/xmlsecurity/inc/xmlsecurity/biginteger.hxx
@@ -27,7 +27,7 @@
#include "com/sun/star/uno/Sequence.h"
OUString bigIntegerToNumericString( ::com::sun::star::uno::Sequence< sal_Int8 > serial );
-::com::sun::star::uno::Sequence< sal_Int8 > numericStringToBigInteger ( OUString serialNumber );
+::com::sun::star::uno::Sequence< sal_Int8 > numericStringToBigInteger ( const OUString& serialNumber );
#endif
diff --git a/xmlsecurity/inc/xmlsecurity/documentsignaturehelper.hxx b/xmlsecurity/inc/xmlsecurity/documentsignaturehelper.hxx
index 361c8d35dad9..61dc500a8f98 100644
--- a/xmlsecurity/inc/xmlsecurity/documentsignaturehelper.hxx
+++ b/xmlsecurity/inc/xmlsecurity/documentsignaturehelper.hxx
@@ -71,7 +71,7 @@ public:
DocumentSignatureMode eDocSigMode );
static std::vector< OUString > CreateElementList(
const css::uno::Reference < css::embed::XStorage >& rxStore,
- const OUString rRootStorageName, DocumentSignatureMode eMode,
+ DocumentSignatureMode eMode,
const DocumentSignatureAlgorithm mode);
static bool isODFPre_1_2(const OUString & sODFVersion);
static bool isOOo3_2_Signature(const SignatureInformation & sigInfo);
diff --git a/xmlsecurity/inc/xmlsecurity/sigstruct.hxx b/xmlsecurity/inc/xmlsecurity/sigstruct.hxx
index 77ab5d85defd..dd80c3939279 100644
--- a/xmlsecurity/inc/xmlsecurity/sigstruct.hxx
+++ b/xmlsecurity/inc/xmlsecurity/sigstruct.hxx
@@ -35,11 +35,11 @@
struct SignatureReferenceInformation
{
- sal_Int32 nType;
+ sal_Int32 nType;
OUString ouURI;
OUString ouDigestValue;
- SignatureReferenceInformation( sal_Int32 type, OUString uri )
+ SignatureReferenceInformation( sal_Int32 type, const OUString& uri )
{
nType = type;
ouURI = uri;
diff --git a/xmlsecurity/inc/xmlsecurity/xmlsignaturehelper.hxx b/xmlsecurity/inc/xmlsecurity/xmlsignaturehelper.hxx
index cf2dc7cdeb9c..dfe9c76325aa 100644
--- a/xmlsecurity/inc/xmlsecurity/xmlsignaturehelper.hxx
+++ b/xmlsecurity/inc/xmlsecurity/xmlsignaturehelper.hxx
@@ -126,7 +126,7 @@ public:
// Set the storage which should be used by the default UriBinding
// Must be set before StatrtMission().
//sODFVersion indicates the ODF version
- void SetStorage( const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& rxStorage, OUString sODFVersion );
+ void SetStorage( const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& rxStorage, const OUString& sODFVersion );
// Argument for the Link is a uno::Reference< xml::sax::XAttributeList >*
// Return 1 to verify, 0 to skip.
diff --git a/xmlsecurity/source/component/documentdigitalsignatures.cxx b/xmlsecurity/source/component/documentdigitalsignatures.cxx
index 896ee9fbea82..3be1610a1d47 100644
--- a/xmlsecurity/source/component/documentdigitalsignatures.cxx
+++ b/xmlsecurity/source/component/documentdigitalsignatures.cxx
@@ -293,7 +293,7 @@ DocumentDigitalSignatures::ImplVerifySignatures(
m_sODFVersion, aSignInfos[n]);
const std::vector< OUString > aElementsToBeVerified =
DocumentSignatureHelper::CreateElementList(
- rxStorage, OUString(), eMode, mode);
+ rxStorage, eMode, mode);
const SignatureInformation& rInfo = aSignInfos[n];
css::security::DocumentSignatureInformation& rSigInfo = arInfos[n];
diff --git a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
index b9452c3b0045..bd297874c708 100644
--- a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
+++ b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
@@ -437,7 +437,7 @@ IMPL_LINK_NOARG(DigitalSignaturesDialog, AddButtonHdl)
std::vector< OUString > aElements =
DocumentSignatureHelper::CreateElementList(
- mxStore, OUString(), meSignatureMode, OOo3_2Document);
+ mxStore, meSignatureMode, OOo3_2Document);
sal_Int32 nElements = aElements.size();
for ( sal_Int32 n = 0; n < nElements; n++ )
@@ -576,7 +576,7 @@ void DigitalSignaturesDialog::ImplFillSignaturesBox()
m_sODFVersion, maCurrentSignatureInformations[n]);
std::vector< OUString > aElementsToBeVerified =
DocumentSignatureHelper::CreateElementList(
- mxStore, OUString(), meSignatureMode, mode);
+ mxStore, meSignatureMode, mode);
const SignatureInformation& rInfo = maCurrentSignatureInformations[n];
//First we try to get the certificate which is embedded in the XML Signature
diff --git a/xmlsecurity/source/helper/documentsignaturehelper.cxx b/xmlsecurity/source/helper/documentsignaturehelper.cxx
index 11f6c6e7f1e9..2ec4f030be80 100644
--- a/xmlsecurity/source/helper/documentsignaturehelper.cxx
+++ b/xmlsecurity/source/helper/documentsignaturehelper.cxx
@@ -76,7 +76,7 @@ int compareVersions(
//then mimetype and all content of META-INF must be excluded.
void ImplFillElementList(
std::vector< OUString >& rList, const Reference < css::embed::XStorage >& rxStore,
- const OUString rRootStorageName, const bool bRecursive,
+ const OUString& rRootStorageName, const bool bRecursive,
const DocumentSignatureAlgorithm mode)
{
OUString aMetaInfName( "META-INF" );
@@ -185,7 +185,7 @@ DocumentSignatureHelper::getDocumentAlgorithm(
std::vector< OUString >
DocumentSignatureHelper::CreateElementList(
const Reference < css::embed::XStorage >& rxStore,
- const OUString /*rRootStorageName*/, DocumentSignatureMode eMode,
+ DocumentSignatureMode eMode,
const DocumentSignatureAlgorithm mode)
{
std::vector< OUString > aElements;
diff --git a/xmlsecurity/source/helper/xmlsignaturehelper.cxx b/xmlsecurity/source/helper/xmlsignaturehelper.cxx
index b5e2869b4031..e32721046306 100644
--- a/xmlsecurity/source/helper/xmlsignaturehelper.cxx
+++ b/xmlsecurity/source/helper/xmlsignaturehelper.cxx
@@ -75,7 +75,7 @@ bool XMLSignatureHelper::Init()
void XMLSignatureHelper::SetStorage(
const Reference < css::embed::XStorage >& rxStorage,
- OUString sODFVersion)
+ const OUString& sODFVersion)
{
DBG_ASSERT( !mxUriBinding.is(), "SetStorage - UriBinding already set!" );
mxUriBinding = new UriBindingHelper( rxStorage );
diff --git a/xmlsecurity/source/helper/xsecctl.hxx b/xmlsecurity/source/helper/xsecctl.hxx
index 0b5469b57541..c45836e99aeb 100644
--- a/xmlsecurity/source/helper/xsecctl.hxx
+++ b/xmlsecurity/source/helper/xsecctl.hxx
@@ -131,7 +131,7 @@ public:
xReferenceResolvedListener = xListener;
}
- void addReference( sal_Int32 type, OUString uri, sal_Int32 keeperId )
+ void addReference( sal_Int32 type, const OUString& uri, sal_Int32 keeperId )
{
signatureInfor.vSignatureReferenceInfors.push_back(
SignatureReferenceInformation(type, uri));
diff --git a/xmlsecurity/source/xmlsec/biginteger.cxx b/xmlsecurity/source/xmlsec/biginteger.cxx
index ae63a291836d..72eb669a09e4 100644
--- a/xmlsecurity/source/xmlsec/biginteger.cxx
+++ b/xmlsecurity/source/xmlsec/biginteger.cxx
@@ -25,7 +25,7 @@
using namespace ::com::sun::star::uno ;
-Sequence< sal_Int8 > numericStringToBigInteger ( OUString numeral )
+Sequence< sal_Int8 > numericStringToBigInteger ( const OUString& numeral )
{
if( numeral.getStr() != NULL )
{