]> git.donarmstrong.com Git - debbugs.git/blobdiff - Debbugs/CGI.pm
Drop more unused variables
[debbugs.git] / Debbugs / CGI.pm
index 34646b81489e4ae8c4f0e5c2a54dfe55ea7b3a0a..9cc4d512426310e48b15f048722834ac34f7b160 100644 (file)
@@ -34,7 +34,7 @@ None known.
 use warnings;
 use strict;
 use vars qw($VERSION $DEBUG %EXPORT_TAGS @EXPORT_OK @EXPORT);
-use base qw(Exporter);
+use Exporter qw(import);
 
 use Debbugs::URI;
 use HTML::Entities;
@@ -292,7 +292,9 @@ sub cgi_parameters {
 
 
 sub quitcgi {
-    my $msg = shift;
+    my ($msg, $status) = @_;
+    $status //= '500 Internal Server Error';
+    print "Status: $status\n";
     print "Content-Type: text/html\n\n";
     print fill_in_template(template=>'cgi/quit',
                           variables => {msg => $msg}
@@ -622,10 +624,6 @@ sub htmlize_maintlinks {
     return htmlize_addresslinks($prefixfunc, \&mainturl, $maints);
 }
 
-
-our $_maintainer;
-our $_maintainer_rev;
-
 =head2 bug_linklist
 
      bug_linklist($separator,$class,@bugs)
@@ -841,7 +839,6 @@ sub option_form{
      for my $key (keys %{$param{form_option}}) {
          # strip out leader; shouldn't be anything here without one,
          # but skip stupid things anyway
-         my $o_key = $key;
          next unless $key =~ s/^\Q$form_option_leader\E//;
          if ($key =~ /^add_(.+)$/) {
               # this causes a specific parameter to be added
@@ -959,7 +956,7 @@ sub calculate_etags {
                     );
     my @additional_data = @{$param{additional_data}};
     for my $file (@{$param{files}}) {
-       my $st = stat($file) or warn "Unable to stat $file:: $!";
+       my $st = stat($file) or warn "Unable to stat $file: $!";
        push @additional_data,$st->mtime;
        push @additional_data,$st->size;
     }