summaryrefslogtreecommitdiff
path: root/stoc/source/defaultregistry
diff options
context:
space:
mode:
Diffstat (limited to 'stoc/source/defaultregistry')
-rw-r--r--stoc/source/defaultregistry/defaultregistry.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/stoc/source/defaultregistry/defaultregistry.cxx b/stoc/source/defaultregistry/defaultregistry.cxx
index ca66017a9e87..c1c07e17079e 100644
--- a/stoc/source/defaultregistry/defaultregistry.cxx
+++ b/stoc/source/defaultregistry/defaultregistry.cxx
@@ -27,6 +27,7 @@
#include <cppuhelper/implementationentry.hxx>
#include <cppuhelper/supportsservice.hxx>
#include <registry/registry.hxx>
+#include <rtl/ref.hxx>
#include <com/sun/star/registry/XSimpleRegistry.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
@@ -1354,10 +1355,9 @@ com_sun_star_comp_stoc_NestedRegistry_get_implementation(
SAL_UNUSED_PARAMETER css::uno::XComponentContext *,
css::uno::Sequence<css::uno::Any> const &)
{
- css::uno::Reference<css::uno::XInterface> x(
- static_cast<cppu::OWeakObject *>(new NestedRegistryImpl));
+ rtl::Reference<NestedRegistryImpl> x(new NestedRegistryImpl);
x->acquire();
- return x.get();
+ return static_cast<cppu::OWeakObject *>(x.get());
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */