Skip to content
Snippets Groups Projects
Commit b7f3ca53 authored by mattijs's avatar mattijs
Browse files

ENH: wmkdep: better error message. See #784.

parent 52bc274b
No related merge requests found
......@@ -4,7 +4,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017 OpenCFD Ltd.
\\/ M anipulation | Copyright (C) 2017-2018 OpenCFD Ltd.
------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
......@@ -471,6 +471,17 @@ static FILE* fopen_file(const char* dirName, const char* fileName)
file = fopen(fullName, "r");
if (!file && errno == EMFILE)
{
fprintf
(
stderr,
EXENAME ": too many open files while opening '%s'\n"
"Please change your open descriptor limit\n",
fullName
);
}
if (file)
{
print_fileName(fullName);
......@@ -482,6 +493,17 @@ static FILE* fopen_file(const char* dirName, const char* fileName)
{
file = fopen(fileName, "r");
if (!file && errno == EMFILE)
{
fprintf
(
stderr,
EXENAME ": too many open files while opening '%s'\n"
"Please change your open descriptor limit\n",
fileName
);
}
if (file)
{
print_fileName(fileName);
......
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