Commit 41fac5b1 authored by Kilian Lackhove's avatar Kilian Lackhove Committed by Chris Cantwell

Addressed Chris remarks

(cherry picked from commit 3255afcf)
parent 0116620a
......@@ -4,6 +4,7 @@ Changelog
v4.3.3
------
**Library**:
- Auto-detect a shared filesystem and removed --shared-filesystem option (!654)
- Fix filters when using adaptive driver to avoid output being overwritten after
each adaptive update (!588)
- Minor fix to suppress Xxt output unless `--verbose` is specified (!642)
......
......@@ -322,19 +322,20 @@ namespace Nektar
{
if (m_comm->GetRank() == 0)
{
std::ofstream testfile ("shared-fs-testfile");
std::ofstream testfile("shared-fs-testfile");
testfile << "" << std::endl;
ASSERTL1(!testfile.fail(), "Test file creation failed");
testfile.close();
}
m_comm->Block();
std::ifstream testfile("shared-fs-testfile");
int exists = (bool) testfile;
int exists = (bool)boost::filesystem::exists("shared-fs-testfile");
m_comm->AllReduce(exists, LibUtilities::ReduceSum);
m_sharedFilesystem = (exists == m_comm->GetSize());
if ((m_sharedFilesystem && m_comm->GetRank() == 0) || !m_sharedFilesystem)
if ((m_sharedFilesystem && m_comm->GetRank() == 0) ||
!m_sharedFilesystem)
{
std::remove("shared-fs-testfile");
}
......@@ -346,7 +347,7 @@ namespace Nektar
if (m_verbose && m_comm->GetRank() == 0 && m_sharedFilesystem)
{
cout << "shared filesystem detected" << endl;
cout << "Shared filesystem detected" << endl;
}
}
......
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