Commit 900cda05 authored by Utkarsh Ayachit's avatar Utkarsh Ayachit Committed by Code Review
Browse files

Merge topic '13101_fix_stl_ascii_reader' into master

fc93e3fc Merge remote branch 'origin/master' into HEAD
54832f74 Updating comment.
1d674588 BUG #13101. STL ascii reader was report failures prematurely.
parents 8c82af8f fc93e3fc
...@@ -442,12 +442,17 @@ int vtkSTLReader::ReadASCIISTL(FILE *fp, vtkPoints *newPts, ...@@ -442,12 +442,17 @@ int vtkSTLReader::ReadASCIISTL(FILE *fp, vtkPoints *newPts,
{ {
if (!fgets(line, 255, fp)) if (!fgets(line, 255, fp))
{ {
vtkErrorMacro ("STLReader error reading file: " << this->FileName // if fgets() returns an error, it may be due to the fact that the EOF
<< " Premature EOF while reading end solid."); // is reached (BUG #13101) hence we test again.
fclose(fp); done = feof(fp);
return 0; if (!done)
{
vtkErrorMacro ("STLReader error reading file: " << this->FileName
<< " Premature EOF while reading end solid.");
fclose(fp);
return 0;
}
} }
done = feof(fp); done = feof(fp);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment