in reply to Directory creation in Perl using mkdir
my $error; mkdir $path or $error = $!; unless (-d $path) { die "Cannot create directory '$path': $error"; }
That should avoid race conditions in directory creation.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Directory creation in Perl using mkdir
by rovf (Priest) on Apr 04, 2011 at 09:44 UTC | |
by moritz (Cardinal) on Apr 04, 2011 at 10:28 UTC |