MantisBT - VTK
View Issue Details
0014515VTK(No Category)public2014-01-15 10:002015-01-09 13:40
Adrian Winterstein 
Sean McBride 
normalminorhave not tried
closedfixed 
6.0.0 
6.2.0 
Kitware
crash
0014515: STL reader crashes on linux if loading an invalid STL file
The vtkSTLReader crashes if an invalid file is loaded. An example file is attached to this report. The crash occurs on line 146 ("fclose(fp);") of vtkStlReader.cxx as fclose is called on an already closed file handle.

The crash only occurs on linux.
hackaton
? InvalidSurface.stl (81) 2014-01-15 10:00
https://www.vtk.org/Bug/file/9598/InvalidSurface.stl
patch stl-fclose.patch (3,296) 2014-01-15 10:02
https://www.vtk.org/Bug/file/9599/stl-fclose.patch
Issue History
2014-01-15 10:00Adrian WintersteinNew Issue
2014-01-15 10:00Adrian WintersteinFile Added: InvalidSurface.stl
2014-01-15 10:02Adrian WintersteinFile Added: stl-fclose.patch
2014-01-15 10:05Adrian WintersteinNote Added: 0032175
2014-10-01 10:47Sean McBrideAssigned To => Sean McBride
2014-10-01 10:47Sean McBrideStatusbacklog => tabled
2014-10-01 10:47Sean McBrideTag Attached: hackaton
2014-10-01 12:40Berk GeveciStatustabled => backlog
2014-10-01 15:02Sean McBrideNote Added: 0033398
2014-10-01 15:02Sean McBrideStatusbacklog => gerrit review
2014-10-01 15:02Sean McBrideResolutionopen => fixed
2014-10-01 15:02Sean McBrideFixed in Version => 6.2.0
2014-10-02 09:22Sean McBrideNote Added: 0033417
2014-10-02 09:22Sean McBrideStatusgerrit review => closed
2015-01-09 13:39Sean McBrideSource_changeset_attached => VTK master dde77d29
2015-01-09 13:40Sean McBrideSource_changeset_attached => VTK master e579693c

Notes
(0032175)
Adrian Winterstein   
2014-01-15 10:05   
I've attached a patch for this issue. Now, the file is only closed in the function where it was opened before (RequestData()). Instead of closing it sometimes inside a subfunction.
(0033398)
Sean McBride   
2014-10-01 15:02   
http://review.source.kitware.com/17304 [^]
(0033417)
Sean McBride   
2014-10-02 09:22   
Merged.