From fba06c0a5f82ddf2f73ef068752d697666464dc1 Mon Sep 17 00:00:00 2001 From: "bugreport%peshkin.net" <> Date: Tue, 27 Jul 2004 22:13:48 +0000 Subject: Bug 252450: Unlock tables in edit*.cgi before sending trailer r=kiko a=justdave --- editversions.cgi | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'editversions.cgi') diff --git a/editversions.cgi b/editversions.cgi index a3a2e2cc5..c426891ed 100755 --- a/editversions.cgi +++ b/editversions.cgi @@ -124,6 +124,7 @@ sub EmitFormElements ($$) sub PutTrailer (@) { my (@links) = ("Back to the query page", @_); + SendSQL("UNLOCK TABLES"); my $count = $#links; my $num = 0; @@ -444,7 +445,6 @@ if ($action eq 'delete') { WHERE product_id = $product_id AND value=" . SqlQuote($version)); print "Version deleted.

\n"; - SendSQL("UNLOCK TABLES"); unlink "$datadir/versioncache"; PutTrailer($localtrailer); @@ -509,13 +509,11 @@ if ($action eq 'update') { unless ($version) { print "Sorry, I can't delete the version text."; PutTrailer($localtrailer); - SendSQL("UNLOCK TABLES"); exit; } if (TestVersion($product,$version)) { print "Sorry, version '$version' is already in use."; PutTrailer($localtrailer); - SendSQL("UNLOCK TABLES"); exit; } SendSQL("UPDATE bugs @@ -530,7 +528,6 @@ if ($action eq 'update') { unlink "$datadir/versioncache"; print "Updated version.
\n"; } - SendSQL("UNLOCK TABLES"); PutTrailer($localtrailer); exit; -- cgit v1.2.3-24-g4f1b