diff options
Diffstat (limited to 'xmlscript/source/xmlflat_imexp/xmlbas_export.cxx')
-rw-r--r-- | xmlscript/source/xmlflat_imexp/xmlbas_export.cxx | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/xmlscript/source/xmlflat_imexp/xmlbas_export.cxx b/xmlscript/source/xmlflat_imexp/xmlbas_export.cxx index 48e14115ea8e..a0793905a54c 100644 --- a/xmlscript/source/xmlflat_imexp/xmlbas_export.cxx +++ b/xmlscript/source/xmlflat_imexp/xmlbas_export.cxx @@ -62,18 +62,16 @@ namespace xmlscript { ::osl::MutexGuard aGuard( m_aMutex ); - if ( aArguments.getLength() == 1 ) + if ( aArguments.getLength() != 1 ) { - aArguments[0] >>= m_xHandler; - - if ( !m_xHandler.is() ) - { - throw RuntimeException( "XMLBasicExporterBase::initialize: invalid argument format!" ); - } + throw RuntimeException( "XMLBasicExporterBase::initialize: invalid number of arguments!" ); } - else + + aArguments[0] >>= m_xHandler; + + if ( !m_xHandler.is() ) { - throw RuntimeException( "XMLBasicExporterBase::initialize: invalid number of arguments!" ); + throw RuntimeException( "XMLBasicExporterBase::initialize: invalid argument format!" ); } } |