summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authormst <mst@openoffice.org>2011-09-17 22:41:28 +0000
committerThorsten Behrens <tbehrens@suse.com>2011-11-29 17:57:29 +0100
commit1b056c65f6d612a00eefe8824c854e4577e4f4be (patch)
tree4f8d0daa2148cfce3bf925e243925969c152354d /sfx2
parentc9e1a120fff37a9d87c4e193cec804d2ac909f90 (diff)
fs34c: #i117625# when assigning events, only throw if there is an invalid type given, *not* if the type is correct, but the sequence is merely empty
* found as LGPLv3-only fix at svn rev 1172123 (http://svn.apache.org/viewvc?view=revision&revision=1172123)
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/notify/eventsupplier.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sfx2/source/notify/eventsupplier.cxx b/sfx2/source/notify/eventsupplier.cxx
index ad1ed19e493a..6c7e2796347c 100644
--- a/sfx2/source/notify/eventsupplier.cxx
+++ b/sfx2/source/notify/eventsupplier.cxx
@@ -84,10 +84,10 @@ void SAL_CALL SfxEvents_Impl::replaceByName( const OUSTRING & aName, const ANY &
{
if ( maEventNames[i] == aName )
{
- const ::comphelper::NamedValueCollection aEventDescriptor( rElement );
// check for correct type of the element
- if ( rElement.hasValue() && aEventDescriptor.empty() )
+ if ( !::comphelper::NamedValueCollection::canExtractFrom( rElement ) )
throw ILLEGALARGUMENTEXCEPTION();
+ ::comphelper::NamedValueCollection const aEventDescriptor( rElement );
// create Configuration at first, creation might call this method also and that would overwrite everything
// we might have stored before!