Skip to content
Snippets Groups Projects
Commit 5d987d5b authored by Spiros Tsalikis's avatar Spiros Tsalikis
Browse files

vtkGenericCell: Return when cell is nullptr

parent 93f15dee
No related branches found
No related tags found
No related merge requests found
......@@ -152,6 +152,7 @@ int vtkGenericCell::SetCellFaces(vtkCellArray* faces)
if (!cell)
{
vtkErrorMacro("SafeDownCast to vtkPolyhedron failed, the cell is not a polyhedron");
return 0;
}
return cell->SetCellFaces(faces);
}
......@@ -163,6 +164,7 @@ vtkCellArray* vtkGenericCell::GetCellFaces()
if (!cell)
{
vtkErrorMacro("SafeDownCast to vtkPolyhedron failed, the cell is not a polyhedron");
return nullptr;
}
return cell->GetCellFaces();
}
......@@ -174,6 +176,7 @@ void vtkGenericCell::GetCellFaces(vtkCellArray* faces)
if (!cell)
{
vtkErrorMacro("SafeDownCast to vtkPolyhedron failed, the cell is not a polyhedron");
return;
}
cell->GetCellFaces(faces);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment