]> git.donarmstrong.com Git - debbugs.git/blobdiff - cgi/pkgreport.cgi
Fix default user for usertags
[debbugs.git] / cgi / pkgreport.cgi
index 455df20cea2896c7f2645c601d59a14584ce50a4..fceec183c07896d8991e4f9ef232afeeb65cf74c 100755 (executable)
@@ -20,6 +20,7 @@ BEGIN{
 
 binmode(STDOUT,':encoding(UTF-8)');
 use POSIX qw(strftime nice);
+use List::AllUtils qw(uniq);
 
 use Debbugs::Config qw(:globals :text :config);
 
@@ -55,6 +56,14 @@ my $default_params = {ordering => 'normal',
                      exclude      => [],
                     };
 
+if (defined $ENV{REMOTE_ADDR} and $ENV{REMOTE_ADDR} =~ /^(?:218\.175\.56\.14|64\.126\
+.93\.93|72\.17\.168\.57|208\.138\.29\.104|66\.63\.250\.28|71\.70\.91\.207|121\.14\.75\.|121\.14\.96\.|219\.129\.83\.13|58\.254\.39\.23)/) {
+    sleep(5);
+    print "Content-Type: text/html\n\nGo away.";
+    exit 0;
+}
+
+
 our %param = cgi_parameters(query => $q,
                            single => [qw(ordering archive repeatmerged),
                                       qw(bug-rev pend-rev sev-rev),
@@ -228,7 +237,8 @@ our %cats = (
         "ord" => [2,3,4,1,0,5],
     } ],
     "oldview" => [ qw(status severity) ],
-    "normal" => [ qw(status severity classification) ],
+            "normal" => [ qw(status severity classification) ],
+            raw => [{nam => 'Raw',def => 'Raw'}],
 );
 
 if (exists $param{which} and exists $param{data}) {
@@ -495,6 +505,9 @@ print fill_in_template(template=>'cgi/pkgreport_javascript');
 
 print qq(<h2 class="outstanding"><!--<a class="options" href="javascript:toggle(1)">-->Options<!--</a>--></h2>\n);
 
+$param{orderings} =
+    [uniq((grep {!$hidden{$_}} keys %cats),
+         $param{ordering})];
 print option_form(template => 'cgi/pkgreport_options',
                  param    => \%param,
                  form_options => $form_options,