From 5b38fda51a4b8a851155a9717e5b4250c3e4c1fd Mon Sep 17 00:00:00 2001 From: David Gobbi Date: Fri, 22 Aug 2025 11:08:25 -0600 Subject: [PATCH 1/2] Fix too-small vector used to store triangle Warning caught by gcc 11.4 -Warray-bounds --- Common/DataModel/vtkPolyhedron.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Common/DataModel/vtkPolyhedron.cxx b/Common/DataModel/vtkPolyhedron.cxx index 3b9d0e64b3c..112b465d7a4 100644 --- a/Common/DataModel/vtkPolyhedron.cxx +++ b/Common/DataModel/vtkPolyhedron.cxx @@ -1555,7 +1555,7 @@ void FindLowestNeighbor(vtkIdType n, vtkIdType* arr, int idx, bool& mustReverse) // therefore the same polygonized border. void TriangulateQuad(vtkCell* quad, FaceVector& faces) { - std::vector consistentTri1(3), consistentTri2(2); + std::vector consistentTri1(3), consistentTri2(3); int l = FindLowestIndex(4, quad->GetPointIds()->GetPointer(0)); bool mustReverse(false); FindLowestNeighbor(4, quad->GetPointIds()->GetPointer(0), l, mustReverse); -- GitLab From eaf31d309d8e5d6739a6fbd13113ee7aad2e64e9 Mon Sep 17 00:00:00 2001 From: David Gobbi Date: Fri, 22 Aug 2025 11:08:51 -0600 Subject: [PATCH 2/2] Fix use of null pointer Warning caught by gcc 11.4 -Wnonnull --- Filters/General/vtkAxisAlignedReflectionFilter.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Filters/General/vtkAxisAlignedReflectionFilter.cxx b/Filters/General/vtkAxisAlignedReflectionFilter.cxx index 6259f1a584d..c30cec13e28 100644 --- a/Filters/General/vtkAxisAlignedReflectionFilter.cxx +++ b/Filters/General/vtkAxisAlignedReflectionFilter.cxx @@ -295,7 +295,8 @@ int vtkAxisAlignedReflectionFilter::RequestData(vtkInformation* vtkNotUsed(reque } else { - vtkErrorMacro("Unhandled data type: " << inputCD->GetClassName()); + vtkDataObject* inputDO = vtkDataObject::GetData(inputVector[0], 0); + vtkErrorMacro("Unhandled data type: " << inputDO->GetClassName()); return 0; } -- GitLab