summaryrefslogtreecommitdiff
path: root/cppuhelper/source
diff options
context:
space:
mode:
Diffstat (limited to 'cppuhelper/source')
-rw-r--r--cppuhelper/source/factory.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/cppuhelper/source/factory.cxx b/cppuhelper/source/factory.cxx
index 6b81ac0da090..649024f667d8 100644
--- a/cppuhelper/source/factory.cxx
+++ b/cppuhelper/source/factory.cxx
@@ -766,9 +766,8 @@ Sequence< OUString > ORegistryFactoryHelper::getSupportedServiceNames()
// Full qualified names like "IMPLEMENTATIONS/TEST/UNO/SERVICES/com.sun.star..."
Sequence<OUString> seqKeys = xKey->getKeyNames();
- OUString* pKeys = seqKeys.getArray();
- for( sal_Int32 i = 0; i < seqKeys.getLength(); i++ )
- pKeys[i] = pKeys[i].copy(nPrefixLen);
+ for( OUString & key : seqKeys )
+ key = key.copy(nPrefixLen);
aServiceNames = seqKeys;
}