summaryrefslogtreecommitdiff
path: root/basic/source/classes/sbxmod.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'basic/source/classes/sbxmod.cxx')
-rw-r--r--basic/source/classes/sbxmod.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx
index 59eb93f665c4..8ca156b1238a 100644
--- a/basic/source/classes/sbxmod.cxx
+++ b/basic/source/classes/sbxmod.cxx
@@ -1317,12 +1317,12 @@ void SbModule::ClearPrivateVars()
}
}
-void SbModule::implClearIfVarDependsOnDeletedBasic( SbxVariable* pVar, StarBASIC* pDeletedBasic )
+void SbModule::implClearIfVarDependsOnDeletedBasic(SbxVariable& rVar, StarBASIC* pDeletedBasic)
{
- if( pVar->SbxValue::GetType() != SbxOBJECT || dynamic_cast<const SbProcedureProperty*>( pVar) != nullptr )
+ if (rVar.SbxValue::GetType() != SbxOBJECT || dynamic_cast<const SbProcedureProperty*>(&rVar) != nullptr)
return;
- SbxObject* pObj = dynamic_cast<SbxObject*>( pVar->GetObject() );
+ SbxObject* pObj = dynamic_cast<SbxObject*>(rVar.GetObject());
if( pObj == nullptr )
return;
@@ -1337,7 +1337,7 @@ void SbModule::implClearIfVarDependsOnDeletedBasic( SbxVariable* pVar, StarBASIC
StarBASIC* pBasic = dynamic_cast<StarBASIC*>( p );
if( pBasic != nullptr && pBasic == pDeletedBasic )
{
- pVar->SbxValue::Clear();
+ rVar.SbxValue::Clear();
break;
}
}
@@ -1358,13 +1358,13 @@ void SbModule::ClearVarsDependingOnDeletedBasic( StarBASIC* pDeletedBasic )
for (sal_uInt32 j = 0; j < pArray->Count(); j++)
{
SbxVariable* pVar = pArray->Get(j);
- implClearIfVarDependsOnDeletedBasic( pVar, pDeletedBasic );
+ implClearIfVarDependsOnDeletedBasic(*pVar, pDeletedBasic);
}
}
}
else
{
- implClearIfVarDependsOnDeletedBasic( p, pDeletedBasic );
+ implClearIfVarDependsOnDeletedBasic(*p, pDeletedBasic);
}
}
}