projects
/
feisty_meow.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
improving this a little bit so it can be used someday.
[feisty_meow.git]
/
scripts
/
files
/
safedel.pl
diff --git
a/scripts/files/safedel.pl
b/scripts/files/safedel.pl
index 30503fa50c4b0f87abbcd5e3b7f8d011e0e85040..ae6f81387451a48e52010e45688187a26288b0cf 100644
(file)
--- a/
scripts/files/safedel.pl
+++ b/
scripts/files/safedel.pl
@@
-72,9
+72,15
@@
sub safedel {
# print "final list of whackees: @to_delete\n";
# we store the deleted files in a directory under the temporary directory.
# print "final list of whackees: @to_delete\n";
# we store the deleted files in a directory under the temporary directory.
- $temp_subdir = $TMP . "/zz_del_keep";
+ if (! -d $TMP) {
+ mkdir "$TMP", 0700;
+ if (! -d $TMP) {
+ die "the TMP directory $TMP could not be created!\n";
+ }
+ }
+ $temp_subdir = $TMP . "/zz_safedel_keep";
if (! -d $temp_subdir) {
if (! -d $temp_subdir) {
- mkdir "$temp_subdir", 07
77
;
+ mkdir "$temp_subdir", 07
00
;
# create the subdirectory under temp if missing.
if (! -d $temp_subdir) {
die "the directory $temp_subdir could not be created!\n";
# create the subdirectory under temp if missing.
if (! -d $temp_subdir) {
die "the directory $temp_subdir could not be created!\n";