Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 543ba01

Browse files
committedMar 12, 2013
filter_api: ensure that the free_text where clauses are always ANDed
Fixes #15573: One query can be issued via current Mantis interface to take down site
1 parent 8afbd34 commit 543ba01

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed
 

‎core/filter_api.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -1996,8 +1996,7 @@ function filter_get_bug_rows( &$p_page_number, &$p_per_page, &$p_page_count, &$p
19961996
# add text query elements to arrays
19971997
if ( !$t_first ) {
19981998
$t_from_clauses[] = "$t_bug_text_table";
1999-
$t_where_clauses[] = "$t_bug_table.bug_text_id = $t_bug_text_table.id";
2000-
$t_where_clauses[] = $t_textsearch_where_clause;
1999+
$t_where_clauses[] = "$t_bug_table.bug_text_id = $t_bug_text_table.id AND $t_textsearch_where_clause";
20012000
$t_join_clauses[] = " LEFT JOIN $t_bugnote_table ON $t_bug_table.id = $t_bugnote_table.bug_id";
20022001
$t_join_clauses[] = " LEFT JOIN $t_bugnote_text_table ON $t_bugnote_table.bugnote_text_id = $t_bugnote_text_table.id";
20032002
}

0 commit comments

Comments
 (0)
Please sign in to comment.