aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--URPM.pm1
-rw-r--r--URPM/Build.pm1
-rw-r--r--URPM/Query.pm1
-rw-r--r--URPM/Resolve.pm4
-rw-r--r--URPM/Signature.pm1
5 files changed, 7 insertions, 1 deletions
diff --git a/URPM.pm b/URPM.pm
index e7d5518..72278a1 100644
--- a/URPM.pm
+++ b/URPM.pm
@@ -1,6 +1,7 @@
package URPM;
use strict;
+use warnings;
use DynaLoader;
# different files, but same package
diff --git a/URPM/Build.pm b/URPM/Build.pm
index 18f3faee..042e4c9 100644
--- a/URPM/Build.pm
+++ b/URPM/Build.pm
@@ -3,6 +3,7 @@ package URPM;
# $Id$
use strict;
+use warnings;
sub _get_tmp_dir () {
my $t = $ENV{TMPDIR};
diff --git a/URPM/Query.pm b/URPM/Query.pm
index 5b62f11..6f58552 100644
--- a/URPM/Query.pm
+++ b/URPM/Query.pm
@@ -1,6 +1,7 @@
package URPM;
use strict;
+use warnings;
# Olivier Thauvin <thauvin@aerov.jussieu.fr>
# This package extend URPM functions to permit
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 {
diff --git a/URPM/Signature.pm b/URPM/Signature.pm
index 0c2eda0..b050f91 100644
--- a/URPM/Signature.pm
+++ b/URPM/Signature.pm
@@ -1,6 +1,7 @@
package URPM;
use strict;
+use warnings;
#- parse from rpmlib db.
#-