diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2004-09-06 07:58:42 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2004-09-06 07:58:42 +0000 |
commit | b46d65c242162f9675aadefe532bb9f66b7e84ef (patch) | |
tree | 8a505f873c06981e74e5e77f293478c4a7303906 /perl-install | |
parent | 75af71f0dd2914044d76f601c4365bfaafe34b06 (diff) | |
download | drakx-backup-do-not-use-b46d65c242162f9675aadefe532bb9f66b7e84ef.tar drakx-backup-do-not-use-b46d65c242162f9675aadefe532bb9f66b7e84ef.tar.gz drakx-backup-do-not-use-b46d65c242162f9675aadefe532bb9f66b7e84ef.tar.bz2 drakx-backup-do-not-use-b46d65c242162f9675aadefe532bb9f66b7e84ef.tar.xz drakx-backup-do-not-use-b46d65c242162f9675aadefe532bb9f66b7e84ef.zip |
BIOS release date can have date DD/MM/YY (or maybe it is MM/DD/YY), only YYYY was handled
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/detect_devices.pm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index 92b7c0b5f..ffe7ceb07 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -747,10 +747,12 @@ sub dmidecode() { } } my $Chassis = $l{Chassis} =~ /^Type:\s*(\S+)/m && $1; + my $BIOS_Year = $l{BIOS} =~ m!^Release Date:.*?(\d{4})!m && $1 || + $l{BIOS} =~ m!^Release Date:.*?\d\d/\d\d/(\d\d)!m && "20$1"; $dmidecode_infos = { isLaptop => member($Chassis, 'Portable', 'Laptop', 'Notebook', 'Sub Notebook', 'Docking Station'), - if_($l{BIOS} =~ /^Release Date:.*?(\d{4})/m, BIOS_Year => $1), + if_($BIOS_Year, BIOS_Year => $BIOS_Year), }; } $dmidecode_infos; |