Commit ec38a93e authored by lpsolit%gmail.com's avatar lpsolit%gmail.com

Bug 183665: Accessing post_bug.cgi directly gives a weird error message and…

Bug 183665: Accessing post_bug.cgi directly gives a weird error message and should redirect to enter_bug.cgi instead - Patch by Matt Tasker <mtasker@gmail.com> (based on the original patch from victory <spam@bmo2007.rsz.jp>) r/a=LpSolit
parent 297024e7
......@@ -45,7 +45,7 @@ sub get_login_info {
my $username = trim($cgi->param("Bugzilla_login"));
my $password = $cgi->param("Bugzilla_password");
$cgi->delete('Bugzilla_login', 'Bugzilla_password');
$cgi->delete('Bugzilla_login', 'Bugzilla_password', 'GoAheadAndLogIn');
if (!defined $username || !defined $password) {
return { failure => AUTH_NODATA };
......
......@@ -53,6 +53,9 @@ my $vars = {};
# Main Script
######################################################################
# redirect to enter_bug if no field is passed.
print $cgi->redirect(correct_urlbase() . 'enter_bug.cgi') unless $cgi->param();
# Detect if the user already used the same form to submit a bug
my $token = trim($cgi->param('token'));
if ($token) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment