Skip to content

Commit

Permalink
Merge pull request #19374 from Dr15Jones/backportLinxContainerFix_5_3
Browse files Browse the repository at this point in the history
Use /proc/self/mounts instead of /etc/mtab
  • Loading branch information
cmsbuild committed Jun 25, 2017
2 parents 6d3ea6e + c2c376e commit 7f06911
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Utilities/StorageFactory/src/LocalFileSystem.cc
Expand Up @@ -223,13 +223,14 @@ LocalFileSystem::initFSList(void)

free(mtab);
#else
const char * const _PATH_MOUNTED_LINUX = "/proc/self/mounts";
struct mntent *m;
FILE *mtab = setmntent(_PATH_MOUNTED, "r");
FILE *mtab = setmntent(_PATH_MOUNTED_LINUX, "r");
if (! mtab)
{
int nerr = errno;
edm::LogWarning("LocalFileSystem::initFSList()")
<< "Cannot read '" << _PATH_MOUNTED << "': "
<< "Cannot read '" << _PATH_MOUNTED_LINUX << "': "
<< strerror(nerr) << " (error " << nerr << ")";
return -1;
}
Expand Down

0 comments on commit 7f06911

Please sign in to comment.