aboutsummaryrefslogtreecommitdiffstats
path: root/URPM/Resolve.pm
diff options
context:
space:
mode:
authorOlivier Thauvin <nanardon@mandriva.org>2010-07-30 00:55:59 +0000
committerOlivier Thauvin <nanardon@mandriva.org>2010-07-30 00:55:59 +0000
commit57c70584abaa14f93fcf104e4b83d9821bfd5995 (patch)
tree1c02c60ecef9b3c1729bb47bda41b909614e8c3e /URPM/Resolve.pm
parent7bc27f76a81245ee8d201587b8031160d8dfbce5 (diff)
downloadperl-URPM-57c70584abaa14f93fcf104e4b83d9821bfd5995.tar
perl-URPM-57c70584abaa14f93fcf104e4b83d9821bfd5995.tar.gz
perl-URPM-57c70584abaa14f93fcf104e4b83d9821bfd5995.tar.bz2
perl-URPM-57c70584abaa14f93fcf104e4b83d9821bfd5995.tar.xz
perl-URPM-57c70584abaa14f93fcf104e4b83d9821bfd5995.zip
- enable 'use warnings'
- fix some warnings
Diffstat (limited to 'URPM/Resolve.pm')
-rw-r--r--URPM/Resolve.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm
index 7e38db8..4090313 100644
--- a/URPM/Resolve.pm
+++ b/URPM/Resolve.pm
@@ -5,6 +5,7 @@ package URPM;
# $Id$
use strict;
+use warnings;
use Config;
@@ -435,7 +436,8 @@ sub _choose_required {
sub pkg2media {
my ($mediums, $p) = @_;
my $id = $p->id;
- find { $id >= $_->{start} && $id <= $_->{end} } @$mediums;
+ #- || 0 to avoid undef, but is it normal to have undef ?
+ find { $id >= ($_->{start} || 0) && $id <= ($_->{end} || 0) } @$mediums;
}
sub whatrequires {