diff options
author | Olivier Blin <oblin@mandriva.org> | 2005-06-03 10:48:17 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2005-06-03 10:48:17 +0000 |
commit | 878459de08a5be8b73377b4f5d53c946447fdf67 (patch) | |
tree | 7c02e6efb35dca8a851aa62cb55879fb5fea3b09 | |
parent | 518affd38b5ea83c5ae5bd1c4bd1b06001ddc5df (diff) | |
download | mgaonline-878459de08a5be8b73377b4f5d53c946447fdf67.tar mgaonline-878459de08a5be8b73377b4f5d53c946447fdf67.tar.gz mgaonline-878459de08a5be8b73377b4f5d53c946447fdf67.tar.bz2 mgaonline-878459de08a5be8b73377b4f5d53c946447fdf67.tar.xz mgaonline-878459de08a5be8b73377b4f5d53c946447fdf67.zip |
use perl_checker compliant md5file() from net_applet (this ought to be moved in some common module, it is used in userdrake as well)
-rwxr-xr-x | mdkapplet | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -26,7 +26,6 @@ use interactive; use common; use Gtk2::Pango; -use Digest::MD5; BEGIN { unshift @::textdomains, 'mdkonline' } @@ -183,11 +182,12 @@ sub showMainWindow() { } sub md5file { my @md5; + require Digest::MD5; foreach my $file (@_) { - open(FILE, $file) or do { print STDERR "Can't open '$file': $!"; push @md5, "" }; - binmode(FILE); - push @md5, Digest::MD5->new->addfile(*FILE)->hexdigest; - close(FILE); + open(my $FILE, $file) or do { print STDERR "Can not open '$file': $!"; push @md5, "" }; + binmode($FILE); + push @md5, Digest::MD5->new->addfile($FILE)->hexdigest; + close($FILE); } return wantarray() ? @md5 : $md5[0]; } |