[Darshan-commits] [Git][darshan/darshan][master] 2 commits: improve error msg if mk-log-dirs fails
Shane Snyder
xgitlab at cels.anl.gov
Tue Dec 1 14:34:51 CST 2020
Shane Snyder pushed to branch master at darshan / darshan
Commits:
00519200 by Phil Carns at 2020-12-01T14:47:59-05:00
improve error msg if mk-log-dirs fails
- - - - -
2d54cd8e by Shane Snyder at 2020-12-01T14:34:49-06:00
Merge branch 'carns/dev-278-mk-log-dirs-error' into 'master'
improve error msg if mk-log-dirs fails
Closes #278
See merge request darshan/darshan!71
- - - - -
1 changed file:
- darshan-runtime/darshan-mk-log-dirs.pl.in
Changes:
=====================================
darshan-runtime/darshan-mk-log-dirs.pl.in
=====================================
@@ -25,7 +25,12 @@ umask(0);
# go through the end of next year
for ($i=$year; $i<($year+2); $i++)
{
- mkdir("$LOGDIR/$i", 0755) or die("Error: could not mkdir $LOGDIR/$i.\n");
+ if(!mkdir("$LOGDIR/$i", 0755))
+ {
+ print STDERR "Error: mkdir($LOGDIR/$i): $!.\n";
+ print STDERR "Error: please make sure that the $LOGDIR directory already exists and is writeable.\n";
+ exit(1);
+ }
for ($j=1; $j<13; $j++)
{
mkdir("$LOGDIR/$i/$j", 0755) or die("Error: could not mkdir $LOGDIR/$i/$j.\n");
View it on GitLab: https://xgitlab.cels.anl.gov/darshan/darshan/-/compare/bf5f027a4565a37dbdc35c9ccda0de6e978af82b...2d54cd8ec96d26db23e9ca421df48d2031a4c55e
--
View it on GitLab: https://xgitlab.cels.anl.gov/darshan/darshan/-/compare/bf5f027a4565a37dbdc35c9ccda0de6e978af82b...2d54cd8ec96d26db23e9ca421df48d2031a4c55e
You're receiving this email because of your account on xgitlab.cels.anl.gov.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/darshan-commits/attachments/20201201/0bd5a84e/attachment-0001.html>
More information about the Darshan-commits
mailing list