diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2013-12-16 16:52:04 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2013-12-16 21:43:12 +0100 |
commit | 9630b973553c7db8e591adb34470228965f01491 (patch) | |
tree | c695c28c46174e4c5e736187dc24c728dcdd330a /cppuhelper | |
parent | ab16d1c619f27864a4a7315932acf2ecb5f16e78 (diff) |
Parser::attrImplementation_ can be a local var
Change-Id: I402040a4b747d457b1b7a3695d0b3567fa7bf478
Diffstat (limited to 'cppuhelper')
-rw-r--r-- | cppuhelper/source/servicemanager.cxx | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/cppuhelper/source/servicemanager.cxx b/cppuhelper/source/servicemanager.cxx index f05ebaf76a18..512fb6be0320 100644 --- a/cppuhelper/source/servicemanager.cxx +++ b/cppuhelper/source/servicemanager.cxx @@ -126,7 +126,6 @@ private: rtl::OUString attrLoader_; rtl::OUString attrUri_; rtl::OUString attrPrefix_; - rtl::OUString attrImplementation_; boost::shared_ptr< cppuhelper::ServiceManager::Data::Implementation > implementation_; }; @@ -326,19 +325,19 @@ void Parser::handleComponent() { } void Parser::handleImplementation() { - attrImplementation_ = getNameAttribute(); + OUString name(getNameAttribute()); implementation_.reset( new cppuhelper::ServiceManager::Data::Implementation( - attrImplementation_, attrLoader_, attrUri_, attrPrefix_, - alienContext_, reader_.getUrl())); + name, attrLoader_, attrUri_, attrPrefix_, alienContext_, + reader_.getUrl())); if (!data_->namedImplementations.insert( cppuhelper::ServiceManager::Data::NamedImplementations::value_type( - attrImplementation_, implementation_)). + name, implementation_)). second) { throw css::registry::InvalidRegistryException( - (reader_.getUrl() + ": duplicate <implementation name=\"" - + attrImplementation_ + "\">"), + (reader_.getUrl() + ": duplicate <implementation name=\"" + name + + "\">"), css::uno::Reference< css::uno::XInterface >()); } } |