summaryrefslogtreecommitdiff
path: root/xmlsecurity/source/helper/documentsignaturemanager.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-08-14 11:14:08 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-08-16 09:04:51 +0200
commit7d7a7862a7dccb6764f80258f28685a0da3cbbcb (patch)
treeb7281950f84b12c4868542f103a23c1460d22863 /xmlsecurity/source/helper/documentsignaturemanager.cxx
parentabeab40aeb2bf16c1438b5e5f0cd70b3e11f6b7a (diff)
new loplugin:sequenceloop
look for places we should be using std::as_const on for-range loops over uno::Sequence, to avoid triggering a copy Change-Id: I7efb641bf09d37c87946f03428ee4eec90298c8a Reviewed-on: https://gerrit.libreoffice.org/77441 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'xmlsecurity/source/helper/documentsignaturemanager.cxx')
-rw-r--r--xmlsecurity/source/helper/documentsignaturemanager.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/xmlsecurity/source/helper/documentsignaturemanager.cxx b/xmlsecurity/source/helper/documentsignaturemanager.cxx
index 557557f6bae8..19cdc2fb4d1d 100644
--- a/xmlsecurity/source/helper/documentsignaturemanager.cxx
+++ b/xmlsecurity/source/helper/documentsignaturemanager.cxx
@@ -177,7 +177,7 @@ bool DocumentSignatureManager::isXML(const OUString& rURI)
if (readManifest())
{
- for (const uno::Sequence<beans::PropertyValue>& entry : m_manifest)
+ for (const uno::Sequence<beans::PropertyValue>& entry : std::as_const(m_manifest))
{
OUString sPath;
OUString sMediaType;
@@ -393,7 +393,7 @@ bool DocumentSignatureManager::add(
eAlgorithmID);
}
- uno::Sequence<uno::Reference<security::XCertificate>> aCertPath
+ const uno::Sequence<uno::Reference<security::XCertificate>> aCertPath
= xSecurityContext->getSecurityEnvironment()->buildCertificatePath(xCert);
OUStringBuffer aStrBuffer;