mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-25 05:20:34 +05:00
fix loading of short mesh file names
This commit is contained in:
parent
3165e04240
commit
e0f3ce9cf0
@ -150,7 +150,7 @@ void Ng_LoadMesh (const char * filename, ngcore::NgMPI_Comm comm)
|
|||||||
mesh->SetCommunicator(comm);
|
mesh->SetCommunicator(comm);
|
||||||
|
|
||||||
string fn(filename);
|
string fn(filename);
|
||||||
if (fn.substr (fn.length()-8, 8) == ".vol.bin")
|
if (fn.length() > 8 && fn.substr (fn.length()-8, 8) == ".vol.bin")
|
||||||
{
|
{
|
||||||
mesh -> Load(fn);
|
mesh -> Load(fn);
|
||||||
SetGlobalMesh (mesh);
|
SetGlobalMesh (mesh);
|
||||||
|
Loading…
Reference in New Issue
Block a user