mirror of
https://github.com/NGSolve/netgen.git
synced 2024-11-11 16:49:16 +05:00
Handle CR and other space characters correctly when loading STL files
This commit is contained in:
parent
7becf20ebd
commit
b3c64a0607
@ -361,7 +361,7 @@ STLGeometry * STLTopology ::Load (istream & ist)
|
||||
|
||||
// Check if there is a non-printable character in first 80 bytes
|
||||
for (auto i : Range(istart, buflen))
|
||||
if(std::isprint(buf[i])==0 && buf[i]!='\n')
|
||||
if(std::isprint(buf[i])==0 && std::isspace(buf[i])==0)
|
||||
return LoadBinary(ist);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user