cannot search for Bugzilla versions which contain commas

RESOLVED DUPLICATE of bug 179309

Status

()

Bugzilla
Query/Bug List
--
minor
RESOLVED DUPLICATE of bug 179309
15 years ago
5 years ago

People

(Reporter: Brian Murphy, Assigned: Dawn Endico)

Tracking

Details

(Reporter)

Description

15 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.0) Gecko/20020623 Debian/1.0.0-0.woody.1
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.0) Gecko/20020623 Debian/1.0.0-0.woody.1

Any bug version specified containing a comma cannot be searched on because of
this code in GenerateSQL in buglist.cgi

    foreach my $field (keys %F) {
        if (lsearch(\@legal_fields, $field) != -1) {
            push(@specialchart, [$field, "anyexact",
                                 join(',', @{$M{$field}})]);
        }
    }

and then a subsequent split on comma at a later point using the ",anyexact"
method:

        ",anyexact" => sub {
             my @list;
             foreach my $w (split(/,/, $v)) {
                 if ($w eq "---" && $f !~ /milestone/) {
                     $w = "";
                 }
                 push(@list, "$ff = " . SqlQuote($w));
             }
             $term = join(" OR ", @list);
         },


Reproducible: Always

Steps to Reproduce:
1. create a version containing a comma
2. create a bug using that version
3. search for bugs with that version

Actual Results:  
I get no bugs returned despite the fact that there is one registered to that
version.

Expected Results:  
The bug with that version should be returned
This is the same as bug 179309. Also see bug 67036.

*** This bug has been marked as a duplicate of 179309 ***
Status: UNCONFIRMED → RESOLVED
Last Resolved: 15 years ago
Resolution: --- → DUPLICATE
QA Contact: matty_is_a_geek → default-qa
You need to log in before you can comment on or make changes to this bug.