From c3d636dd3b8d9ae344f85b33032f87b5592b5a47 Mon Sep 17 00:00:00 2001 From: Kirill Miazine Date: Sun, 2 Jul 2017 15:04:16 +0200 Subject: [PATCH] Use q->multi_param() when multiple values are expected. --- cgi-bin/show_failures.pl | 6 +++--- cgi-bin/show_status.pl | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cgi-bin/show_failures.pl b/cgi-bin/show_failures.pl index 62d186e..ffdcef9 100755 --- a/cgi-bin/show_failures.pl +++ b/cgi-bin/show_failures.pl @@ -19,12 +19,12 @@ use FindBin qw($RealBin); require "$RealBin/../BuildFarmWeb.pl"; my $query = new CGI; -my @members = grep {$_ ne "" } $query->param('member'); +my @members = grep {$_ ne "" } $query->multi_param('member'); map { s/[^a-zA-Z0-9_ -]//g; } @members; my $max_days = $query->param('max_days') + 0 || 10; -my @branches = grep {$_ ne "" } $query->param('branch'); +my @branches = grep {$_ ne "" } $query->multi_param('branch'); map { s/[^a-zA-Z0-9_ .-]//g; } @branches; -my @stages = grep {$_ ne "" } $query->param('stage'); +my @stages = grep {$_ ne "" } $query->multi_param('stage'); map { s/[^a-zA-Z0-9_ :-]//g; } @stages; my $dsn="dbi:Pg:dbname=$dbname"; diff --git a/cgi-bin/show_status.pl b/cgi-bin/show_status.pl index 6bc9fc6..d14644c 100755 --- a/cgi-bin/show_status.pl +++ b/cgi-bin/show_status.pl @@ -19,7 +19,7 @@ use FindBin qw($RealBin); require "$RealBin/../BuildFarmWeb.pl"; my $query = new CGI; -my @members = $query->param('member'); +my @members = $query->multi_param('member'); map { s/[^a-zA-Z0-9_ -]//g; } @members; my $dsn="dbi:Pg:dbname=$dbname"; -- 2.30.2