summaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2012-08-31 12:31:04 +0200
committerFrédéric Buclin <LpSolit@gmail.com>2012-08-31 12:31:04 +0200
commit3088b1d2724d7959ea87e84cab98963e2d2c3e72 (patch)
tree1e2d34957160e9375539f8e03a025e984455f7ab /Bugzilla
parentab612efff307c445c25d010ac8a2eaba6fd93228 (diff)
downloadbugzilla-3088b1d2724d7959ea87e84cab98963e2d2c3e72.tar.gz
bugzilla-3088b1d2724d7959ea87e84cab98963e2d2c3e72.tar.xz
Bug 655477: Bugzilla now requires Perl 5.10.1
r=mkanat a=LpSolit
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/DB.pm8
-rw-r--r--Bugzilla/Install/CPAN.pm13
-rw-r--r--Bugzilla/Install/Requirements.pm12
-rw-r--r--Bugzilla/Util.pm21
4 files changed, 7 insertions, 47 deletions
diff --git a/Bugzilla/DB.pm b/Bugzilla/DB.pm
index 89a0140d7..7d289aaa1 100644
--- a/Bugzilla/DB.pm
+++ b/Bugzilla/DB.pm
@@ -1246,11 +1246,9 @@ sub db_new {
ShowErrorStatement => 1,
HandleError => \&_handle_error,
TaintIn => 1,
- FetchHashKeyName => 'NAME',
- # Note: NAME_lc causes crash on ActiveState Perl
- # 5.8.4 (see Bug 253696)
- # XXX - This will likely cause problems in DB
- # back ends that twiddle column case (Oracle?)
+ # See https://rt.perl.org/rt3/Public/Bug/Display.html?id=30933
+ # for the reason to use NAME instead of NAME_lc (bug 253696).
+ FetchHashKeyName => 'NAME',
};
if ($override_attrs) {
diff --git a/Bugzilla/Install/CPAN.pm b/Bugzilla/Install/CPAN.pm
index 92ab5a267..10e0cce66 100644
--- a/Bugzilla/Install/CPAN.pm
+++ b/Bugzilla/Install/CPAN.pm
@@ -167,20 +167,9 @@ sub install_module {
if (!$module) {
die install_string('no_such_module', { module => $name }) . "\n";
}
- my $version = $module->cpan_version;
- my $module_name = $name;
-
- if ($name eq 'LWP::UserAgent' && $^V lt v5.8.8) {
- # LWP 6.x requires Perl 5.8.8 or newer.
- # As PAUSE only indexes the very last version of each module,
- # we have to specify the path to the tarball ourselves.
- $name = 'GAAS/libwww-perl-5.837.tar.gz';
- # This tarball contains LWP::UserAgent 5.835.
- $version = '5.835';
- }
print install_string('install_module',
- { module => $module_name, version => $version }) . "\n";
+ { module => $name, version => $module->cpan_version }) . "\n";
if ($test) {
CPAN::Shell->force('install', $name);
diff --git a/Bugzilla/Install/Requirements.pm b/Bugzilla/Install/Requirements.pm
index c5abf1986..24aa1cb82 100644
--- a/Bugzilla/Install/Requirements.pm
+++ b/Bugzilla/Install/Requirements.pm
@@ -562,21 +562,11 @@ sub print_module_instructions {
# We only print the PPM repository note if we have to.
my $perl_ver = sprintf('%vd', $^V);
if ($need_module_instructions && ON_ACTIVESTATE && vers_cmp($perl_ver, '5.12') < 0) {
- # URL when running Perl 5.8.x.
- my $url_to_theory58S = 'http://theoryx5.uwinnipeg.ca/ppms';
- # Packages for Perl 5.10 are not compatible with Perl 5.8.
- if (vers_cmp($perl_ver, '5.10') > -1) {
- $url_to_theory58S = 'http://cpan.uwinnipeg.ca/PPMPackages/10xx/';
- }
+ my $url_to_theory58S = 'http://cpan.uwinnipeg.ca/PPMPackages/10xx/';
print colored(
install_string('ppm_repo_add',
{ theory_url => $url_to_theory58S }),
COLOR_ERROR);
-
- # ActivePerls older than revision 819 require an additional command.
- if (ON_ACTIVESTATE < 819) {
- print install_string('ppm_repo_up');
- }
}
if ($need_module_instructions or @{ $check_results->{apache} }) {
diff --git a/Bugzilla/Util.pm b/Bugzilla/Util.pm
index 810c6972f..78ef21e1d 100644
--- a/Bugzilla/Util.pm
+++ b/Bugzilla/Util.pm
@@ -8,6 +8,7 @@
package Bugzilla::Util;
use strict;
+use feature ':5.10';
use base qw(Exporter);
@Bugzilla::Util::EXPORT = qw(trick_taint detaint_natural detaint_signed
@@ -404,13 +405,6 @@ sub diff_arrays {
return (\@removed, \@added);
}
-# XXX - This is a temporary subroutine till we require Perl 5.10.1.
-# This will happen before Bugzilla 5.0rc1.
-sub say (@) {
- print @_;
- print "\n";
-}
-
sub trim {
my ($str) = @_;
if ($str) {
@@ -437,11 +431,6 @@ sub wrap_comment {
$wrappedcomment .= ($line . "\n");
}
else {
- # Due to a segfault in Text::Tabs::expand() when processing tabs with
- # Unicode (see http://rt.perl.org/rt3/Public/Bug/Display.html?id=52104),
- # we have to remove tabs before processing the comment. This restriction
- # can go away when we require Perl 5.8.9 or newer.
- $line =~ s/\t/ /g;
$wrappedcomment .= (wrap('', '', $line) . "\n");
}
}
@@ -590,15 +579,9 @@ sub bz_crypt {
if (Bugzilla->params->{'utf8'}) {
utf8::encode($password) if utf8::is_utf8($password);
}
-
+
# Crypt the password.
$crypted_password = crypt($password, $salt);
-
- # HACK: Perl has bug where returned crypted password is considered
- # tainted. See http://rt.perl.org/rt3/Public/Bug/Display.html?id=59998
- unless(tainted($password) || tainted($salt)) {
- trick_taint($crypted_password);
- }
}
else {
my $hasher = Digest->new($algorithm);