summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-03-02 14:22:50 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-03-02 14:22:50 +0000
commit9abdd5c94d13cddf74c074276a4ed0c310e2a32e (patch)
tree97a2b0097a9b37d2cb514c91a6af9bc69322cdd9 /perl-install
parentb4c938adf99d9ce1fcab46121e3a7c4ccb2a5acd (diff)
downloaddrakx-9abdd5c94d13cddf74c074276a4ed0c310e2a32e.tar
drakx-9abdd5c94d13cddf74c074276a4ed0c310e2a32e.tar.gz
drakx-9abdd5c94d13cddf74c074276a4ed0c310e2a32e.tar.bz2
drakx-9abdd5c94d13cddf74c074276a4ed0c310e2a32e.tar.xz
drakx-9abdd5c94d13cddf74c074276a4ed0c310e2a32e.zip
(removeXiBSuffix): enhanced, more flexible
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/common.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/perl-install/common.pm b/perl-install/common.pm
index ef141fe68..83ce5d198 100644
--- a/perl-install/common.pm
+++ b/perl-install/common.pm
@@ -600,9 +600,9 @@ sub setVirtual($) {
sub removeXiBSuffix($) {
local $_ = shift;
- /(\d+)k$/i and return $1 * 1024;
- /(\d+)M$/i and return $1 * 1024 * 1024;
- /(\d+)G$/i and return $1 * 1024 * 1024 * 1024;
+ /(\d+)\s*kB?$/i and return $1 * 1024;
+ /(\d+)\s*MB?$/i and return $1 * 1024 * 1024;
+ /(\d+)\s*GB?$/i and return $1 * 1024 * 1024 * 1024;
$_;
}
sub formatXiB {