From 54fc279f6268e854049944a46b3cc5c036636c37 Mon Sep 17 00:00:00 2001
From: Raine Yeh <raine.yeh@gmail.com>
Date: Sat, 30 Nov 2013 01:14:21 -0500
Subject: [PATCH 4497/4497] Fix vtkHyperStreamline from seg-faulting when input
 data has no scalar array

---
 Filters/General/vtkHyperStreamline.cxx | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/Filters/General/vtkHyperStreamline.cxx b/Filters/General/vtkHyperStreamline.cxx
index 1ff328c..d325ce1 100644
--- a/Filters/General/vtkHyperStreamline.cxx
+++ b/Filters/General/vtkHyperStreamline.cxx
@@ -371,7 +371,7 @@ int vtkHyperStreamline::RequestData(
   inScalars = pd->GetScalars();
 
   cellTensors = vtkDataArray::CreateDataArray(inTensors->GetDataType());
-  cellScalars = vtkDataArray::CreateDataArray(inScalars->GetDataType());
+  
   int numComp;
   if (inTensors)
     {
@@ -381,6 +381,7 @@ int vtkHyperStreamline::RequestData(
     }
   if (inScalars)
     {
+	cellScalars = vtkDataArray::CreateDataArray(inScalars->GetDataType());
     numComp = inScalars->GetNumberOfComponents();
     cellScalars->SetNumberOfComponents(numComp);
     cellScalars->SetNumberOfTuples(VTK_CELL_SIZE);
@@ -646,7 +647,7 @@ int vtkHyperStreamline::RequestData(
 
   delete [] w;
   cellTensors->Delete();
-  cellScalars->Delete();
+  if (inScalars) cellScalars->Delete();
 
   return retval;
 }
-- 
1.8.3.msysgit.0

