Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
48bc6d39
Commit
48bc6d39
authored
Sep 28, 2013
by
Frédéric Buclin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 851267: Bugzilla times out when a user has several thousands of votes
r=dkl a=justdave
parent
5d0e6171
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
93 additions
and
96 deletions
+93
-96
CGI.pm
Bugzilla/CGI.pm
+4
-4
Extension.pm
extensions/Voting/Extension.pm
+80
-82
user.html.tmpl
...ns/Voting/template/en/default/pages/voting/user.html.tmpl
+9
-10
No files found.
Bugzilla/CGI.pm
View file @
48bc6d39
...
@@ -473,9 +473,9 @@ sub redirect_search_url {
...
@@ -473,9 +473,9 @@ sub redirect_search_url {
# GET requests that lacked a list_id are always redirected. POST requests
# GET requests that lacked a list_id are always redirected. POST requests
# are only redirected if they're under the CGI_URI_LIMIT though.
# are only redirected if they're under the CGI_URI_LIMIT though.
my
$
uri_length
=
length
(
$self
->
self_url
()
);
my
$
self_url
=
$self
->
self_url
(
);
if
(
$self
->
request_method
()
ne
'POST'
or
$uri_length
<
CGI_URI_LIMIT
)
{
if
(
$self
->
request_method
()
ne
'POST'
or
length
(
$self_url
)
<
CGI_URI_LIMIT
)
{
print
$self
->
redirect
(
-
url
=>
$self
->
self_url
()
);
print
$self
->
redirect
(
-
url
=>
$self
_url
);
exit
;
exit
;
}
}
}
}
...
@@ -529,7 +529,7 @@ sub url_is_attachment_base {
...
@@ -529,7 +529,7 @@ sub url_is_attachment_base {
$regex
=~
s/\\\%bugid\\\%/\\d+/
;
$regex
=~
s/\\\%bugid\\\%/\\d+/
;
}
}
$regex
=
"^$regex"
;
$regex
=
"^$regex"
;
return
(
$self
->
self_
url
=~
$regex
)
?
1
:
0
;
return
(
$self
->
url
=~
$regex
)
?
1
:
0
;
}
}
sub
set_dated_content_disp
{
sub
set_dated_content_disp
{
...
...
extensions/Voting/Extension.pm
View file @
48bc6d39
This diff is collapsed.
Click to expand it.
extensions/Voting/template/en/default/pages/voting/user.html.tmpl
View file @
48bc6d39
...
@@ -85,8 +85,7 @@
...
@@ -85,8 +85,7 @@
</tr>
</tr>
[% FOREACH bug = product.bugs %]
[% FOREACH bug = product.bugs %]
<tr [% IF bug.id == this_bug.id && canedit %]
<tr [% IF bug.id == this_bug.id && canedit %] class="bz_bug_being_voted_on"[% END %]>
class="bz_bug_being_voted_on" [% END %]>
<td>
<td>
[% IF bug.id == this_bug.id && canedit %]
[% IF bug.id == this_bug.id && canedit %]
[% IF product.onevoteonly %]
[% IF product.onevoteonly %]
...
@@ -96,25 +95,25 @@
...
@@ -96,25 +95,25 @@
[% END %]
[% END %]
[%- END %]
[%- END %]
</td>
</td>
<td align="right"><a name="vote_[% bug.id FILTER
html
%]">
<td align="right"><a name="vote_[% bug.id FILTER
none
%]">
[% IF canedit %]
[% IF canedit %]
[% IF product.onevoteonly %]
[% IF product.onevoteonly %]
<input type="checkbox" name="[% bug.id FILTER
html
%]" value="1"
<input type="checkbox" name="[% bug.id FILTER
none
%]" value="1"
[% " checked" IF bug.count %] id="bug_[% bug.id FILTER
html
%]">
[% " checked" IF bug.count %] id="bug_[% bug.id FILTER
none
%]">
[% ELSE %]
[% ELSE %]
<input name="[% bug.id FILTER
html
%]" value="[% bug.count FILTER html %]"
<input name="[% bug.id FILTER
none
%]" value="[% bug.count FILTER html %]"
size="2" id="bug_[% bug.id FILTER
html
%]">
size="2" id="bug_[% bug.id FILTER
none
%]">
[% END %]
[% END %]
[% ELSE %]
[% ELSE %]
[% bug.count FILTER html %]
[% bug.count FILTER html %]
[% END %]
[% END %]
</a></td>
</a></td>
<td align="center">
<td align="center">
[%
bug.id FILTER bug_link(bug.id) FILTER none
%]
[%
PROCESS bug/link.html.tmpl bug = bug, link_text = bug.id
%]
</td>
</td>
<td>
<td>
[% bug.s
ummary
FILTER html %]
[% bug.s
hort_desc
FILTER html %]
(<a href="page.cgi?id=voting/bug.html&bug_id=[% bug.id FILTER
uri
%]">Show Votes</a>)
(<a href="page.cgi?id=voting/bug.html&bug_id=[% bug.id FILTER
none
%]">Show Votes</a>)
</td>
</td>
</tr>
</tr>
[% END %]
[% END %]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment