summaryrefslogtreecommitdiff
path: root/unotest
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2015-03-30 16:51:13 +0300
committerTor Lillqvist <tml@collabora.com>2015-03-30 16:51:24 +0300
commit32423f6f877397be5d3358cbcba5f105e9715a1f (patch)
tree4ace95ca2dc0e7cb054a83970a83b32aa0f26c8a /unotest
parent45cfdae9b195d5fa89dd46c6035fc36d63ebc515 (diff)
WaE: passing [...] by value, rather pass by reference
Change-Id: Ic733f9b5dcb55bb8120c3652a60300914fab04ea
Diffstat (limited to 'unotest')
-rw-r--r--unotest/source/cpp/macros_test.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/unotest/source/cpp/macros_test.cxx b/unotest/source/cpp/macros_test.cxx
index 02b14ba9f3e3..7dce6ef54567 100644
--- a/unotest/source/cpp/macros_test.cxx
+++ b/unotest/source/cpp/macros_test.cxx
@@ -19,7 +19,7 @@ using namespace css;
namespace unotest {
-uno::Reference<css::lang::XComponent> MacrosTest::loadFromDesktop(const OUString& rURL, const OUString& rDocService, uno::Sequence<beans::PropertyValue> extraArgs)
+uno::Reference<css::lang::XComponent> MacrosTest::loadFromDesktop(const OUString& rURL, const OUString& rDocService, const uno::Sequence<beans::PropertyValue>& rExtraArgs)
{
CPPUNIT_ASSERT_MESSAGE("no desktop", mxDesktop.is());
uno::Reference<frame::XComponentLoader> xLoader = uno::Reference<frame::XComponentLoader>(mxDesktop, uno::UNO_QUERY);
@@ -39,16 +39,16 @@ uno::Reference<css::lang::XComponent> MacrosTest::loadFromDesktop(const OUString
args[1].State = beans::PropertyState_DIRECT_VALUE;
}
- if (extraArgs.getLength() > 0)
+ if (rExtraArgs.getLength() > 0)
{
sal_Int32 aSize = args.getLength();
- args.realloc(aSize + extraArgs.getLength());
- for (int i = 0; i < extraArgs.getLength(); i++)
+ args.realloc(aSize + rExtraArgs.getLength());
+ for (int i = 0; i < rExtraArgs.getLength(); i++)
{
- args[aSize + i].Name = extraArgs[i].Name;
- args[aSize + i].Handle = extraArgs[i].Handle;
- args[aSize + i].Value = extraArgs[i].Value;
- args[aSize + i].State = extraArgs[i].State;
+ args[aSize + i].Name = rExtraArgs[i].Name;
+ args[aSize + i].Handle = rExtraArgs[i].Handle;
+ args[aSize + i].Value = rExtraArgs[i].Value;
+ args[aSize + i].State = rExtraArgs[i].State;
}
}