diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-04-27 09:54:09 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-04-27 13:47:30 +0200 |
commit | 81105d9534979b6d14a5ceb58e70845892d550fa (patch) | |
tree | e1decb2f0cc8a528f0dd78532a6b258aad359617 /svtools | |
parent | d3f80583ee90c9b652ac5d1ef8957ec0db65fdd2 (diff) |
-Werror,-Wvarargs
"passing an object that undergoes default argument promotion to 'va_start' has
undefined behavior [-Werror,-Wvarargs]"
just drop the variadic overload and use the one taking a WizardPath (i.e., a vector)
Change-Id: I6e389f60f8b7cb0633bf173bde69af1c5af86048
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/dialogs/roadmapwizard.cxx | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/svtools/source/dialogs/roadmapwizard.cxx b/svtools/source/dialogs/roadmapwizard.cxx index eb0730cbb7b5..1df26b6c275b 100644 --- a/svtools/source/dialogs/roadmapwizard.cxx +++ b/svtools/source/dialogs/roadmapwizard.cxx @@ -24,8 +24,6 @@ #include <roadmap.hxx> #include <tools/debug.hxx> -#include <stdarg.h> - #include <vector> #include <map> #include <set> @@ -182,35 +180,6 @@ namespace svt } - void RoadmapWizard::declarePath( PathId _nPathId, WizardState _nFirstState, ... ) - { - - DBG_ASSERT( _nFirstState != WZS_INVALID_STATE, "RoadmapWizard::declarePath: there should be at least one state in the path!" ); - if ( _nFirstState == WZS_INVALID_STATE ) - return; - - WizardPath aNewPath; - - // collect the elements of the path - va_list aStateList; - va_start( aStateList, _nFirstState ); - - WizardState nState = _nFirstState; - while ( nState != WZS_INVALID_STATE ) - { - aNewPath.push_back( nState ); - nState = sal::static_int_cast< WizardState >( - va_arg( aStateList, int )); - } - va_end( aStateList ); - - DBG_ASSERT( _nFirstState == 0, "RoadmapWizard::declarePath: first state must be NULL." ); - // The WizardDialog (our very base class) always starts with a mnCurLevel == 0 - - declarePath( _nPathId, aNewPath ); - } - - void RoadmapWizard::describeState( WizardState _nState, const OUString& _rStateDisplayName, RoadmapPageFactory _pPageFactory ) { OSL_ENSURE( m_pImpl->aStateDescriptors.find( _nState ) == m_pImpl->aStateDescriptors.end(), |