summaryrefslogtreecommitdiff
path: root/vcl/source/control/wizardmachine.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source/control/wizardmachine.cxx')
-rw-r--r--vcl/source/control/wizardmachine.cxx12
1 files changed, 9 insertions, 3 deletions
diff --git a/vcl/source/control/wizardmachine.cxx b/vcl/source/control/wizardmachine.cxx
index 839c43e81842..2b3397573612 100644
--- a/vcl/source/control/wizardmachine.cxx
+++ b/vcl/source/control/wizardmachine.cxx
@@ -1153,11 +1153,17 @@ namespace vcl
{
if ( isTravelingSuspended() )
return;
- WizardTravelSuspension aTravelGuard( *this );
- if (!prepareLeaveCurrentState(WizardTypes::eFinish))
+
+ // prevent WizardTravelSuspension from using this instance
+ // after will be destructed due to onFinish and async response call
{
- return;
+ WizardTravelSuspension aTravelGuard( *this );
+ if (!prepareLeaveCurrentState(WizardTypes::eFinish))
+ {
+ return;
+ }
}
+
onFinish();
}