summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2004-03-09 13:40:57 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2004-03-09 13:40:57 +0000
commit7980020d2bd3a5402cc52fbddd3bb2072457d251 (patch)
treec8488506db4208eead949ef23623d6fb389c0b14 /perl-install/standalone
parent7b326b8fb9f487c37a746859f471d97eb6b8318c (diff)
downloaddrakx-7980020d2bd3a5402cc52fbddd3bb2072457d251.tar
drakx-7980020d2bd3a5402cc52fbddd3bb2072457d251.tar.gz
drakx-7980020d2bd3a5402cc52fbddd3bb2072457d251.tar.bz2
drakx-7980020d2bd3a5402cc52fbddd3bb2072457d251.tar.xz
drakx-7980020d2bd3a5402cc52fbddd3bb2072457d251.zip
(the_time) simplify
Diffstat (limited to 'perl-install/standalone')
-rwxr-xr-xperl-install/standalone/drakbackup16
1 files changed, 2 insertions, 14 deletions
diff --git a/perl-install/standalone/drakbackup b/perl-install/standalone/drakbackup
index 92ff537ea..588236607 100755
--- a/perl-install/standalone/drakbackup
+++ b/perl-install/standalone/drakbackup
@@ -282,20 +282,8 @@ sub all_user_list() {
}
sub the_time() {
- $the_time = "_";
- my ($sec, $min, $hour, $day, $month, $year) = localtime(time());
- $the_time .= $year + 1900;
- if ($month < 9) { $the_time .= "0" }
- $the_time .= $month + 1;
- if ($day < 10) { $the_time .= "0" }
- $the_time .= $day;
- $the_time .= "_";
- if ($hour < 10) { $the_time .= "0" }
- $the_time .= $hour;
- if ($min < 10) { $the_time .= "0" }
- $the_time .= $min;
- if ($sec < 10) { $the_time .= "0" }
- $the_time .= $sec;
+ my ($sec, $min, $hour, $day, $month, $year) = localtime(time());
+ sprintf("_%d%02d%02d_%02d%02d%02d", $year + 1900, $month + 1, $day, $hour, $min, $sec);
}
sub get_tape_info() {