Commit 6fc68f38 authored by Frédéric Buclin's avatar Frédéric Buclin

Bug 593881: Assignment to $[ has been deprecated in Perl 5.12.0

r/a=mkanat
parent 70d2f4a0
......@@ -144,7 +144,7 @@ elsif ($action eq 'begin-sudo') {
# If we have a reason passed in, keep it under 200 characters
my $reason = $cgi->param('reason') || '';
$reason = substr($reason, $[, 200);
$reason = substr($reason, 0, 200);
# Calculate the session expiry time (T + 6 hours)
my $time_string = time2str('%a, %d-%b-%Y %T %Z', time + MAX_SUDO_TOKEN_AGE, 'GMT');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment