fix dat dagen altijd 2 chars moeten zijn
This commit is contained in:
parent
91f90b825f
commit
84fca7e6ae
1 changed files with 1 additions and 0 deletions
|
|
@ -36,6 +36,7 @@ sub backup($) {
|
|||
@stat = stat($file);
|
||||
@timestamp = localtime($stat[9]);
|
||||
$timestamp[5] += 1900;
|
||||
if ( length($timestamp[3]) < 2 ) { $timestamp[3] = "0$timestamp[3]"; }
|
||||
$sfx = "$timestamp[3]$months[$timestamp[4]]$timestamp[5]";
|
||||
unless ( -d "$dir/OLD" ) { mkdir "$dir/OLD", 0777 or die "Couldn't create $dir/OLD: $!\n"; }
|
||||
$backup = "$dir/OLD/$base.$sfx";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue