summaryrefslogtreecommitdiff
path: root/comphelper
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-12-19 20:52:25 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-12-19 20:52:25 +0100
commit962d4b35bd53e3d37849acd325dc57861c930972 (patch)
treea760815b54d64a4b266c32859a02cf6ec3294a68 /comphelper
parent52be0a739642aa10bf5ec81c512ff0a9ca854eed (diff)
css.logging.SimpleLogRing.create() calls initialize w/ empty Arguments
Change-Id: Iffcab3831b40ce309aa20fdb825328ebb4dd1064
Diffstat (limited to 'comphelper')
-rw-r--r--comphelper/source/misc/documentiologring.cxx15
1 files changed, 9 insertions, 6 deletions
diff --git a/comphelper/source/misc/documentiologring.cxx b/comphelper/source/misc/documentiologring.cxx
index 5b943643bf2b..a2e9de1f7447 100644
--- a/comphelper/source/misc/documentiologring.cxx
+++ b/comphelper/source/misc/documentiologring.cxx
@@ -123,14 +123,17 @@ void SAL_CALL OSimpleLogRing::initialize( const uno::Sequence< uno::Any >& aArgu
if ( !m_refCount )
throw uno::RuntimeException(); // the object must be refcounted already!
- sal_Int32 nLen = 0;
- if ( aArguments.getLength() == 1 && ( aArguments[0] >>= nLen ) && nLen )
- m_aMessages.realloc( nLen );
- else
- throw lang::IllegalArgumentException(
- OUString( "Nonnull size is expected as the first argument!" ),
+ if (aArguments.hasElements())
+ {
+ sal_Int32 nLen = 0;
+ if ( aArguments.getLength() == 1 && ( aArguments[0] >>= nLen ) && nLen )
+ m_aMessages.realloc( nLen );
+ else
+ throw lang::IllegalArgumentException(
+ "Nonnull size is expected as the first argument!",
uno::Reference< uno::XInterface >(),
0 );
+ }
m_bInitialized = sal_True;
}