From cf85fdf7daadb8eecca0963855cc3e11d112bfd1 Mon Sep 17 00:00:00 2001 From: apo Date: Mon, 17 Oct 2005 07:07:59 +0000 Subject: [PATCH] Minor changes --- src/OBJECT/VISU_GaussPtsAct.cxx | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/OBJECT/VISU_GaussPtsAct.cxx b/src/OBJECT/VISU_GaussPtsAct.cxx index ab61fee0..5b3370dc 100644 --- a/src/OBJECT/VISU_GaussPtsAct.cxx +++ b/src/OBJECT/VISU_GaussPtsAct.cxx @@ -459,15 +459,11 @@ VISU_GaussPtsAct //---------------------------------------------------------------------------- bool VISU_GaussPtsAct::IsInfinitive() { - vtkMapper *pMapper =GetMapper(); - vtkDataSet* pDS=pMapper->GetInput(); - pDS->Update(); - int aNb=pDS->GetNumberOfCells(); - if (aNb<2) { - myIsInfinite=true; + if(vtkMapper* aMapper = GetMapper()){ + if(vtkDataSet* aDataSet= aMapper->GetInput()){ + aDataSet->Update(); + myIsInfinite = aDataSet->GetNumberOfCells() < 2; } - else{ - myIsInfinite=false; } return myIsInfinite; } -- 2.39.2