]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Patch for bug 277303: checksetup.pl shouldn't emit a syntax error when trying to...
authorjocuri%softhome.net <>
Sun, 9 Jan 2005 02:09:28 +0000 (02:09 +0000)
committerjocuri%softhome.net <>
Sun, 9 Jan 2005 02:09:28 +0000 (02:09 +0000)
checksetup.pl

index 7e77af97fd7ec910f6ac4d81922a41881a9c82f2..f9e93835e72616dc67d8b9ac6602c046b61bdce9 100755 (executable)
@@ -3443,15 +3443,8 @@ if (GetFieldDef("products", "product")) {
                  " AND product_id = $product_id");
     }
     print "Fixing Indexes and Uniqueness.\n";
-    $dbh->do("ALTER TABLE milestones DROP INDEX product");
-
-    # mkanat@kerio.com - bug 244756
-    # Silently drop the PRIMARY key if a buggy mysqldump has put it there.
-    # Don't print any error messages if the index isn't there.
-    my $originalprintwarn = $dbh->{'PrintWarn'};
-    $dbh->{'PrintWarn'} = 0;
-    $dbh->do("ALTER TABLE milestones DROP INDEX PRIMARY");
-    $dbh->{'PrintWarn'} = $originalprintwarn;
+    # Drop any indexes that may exist on the milestones table.
+    DropIndexes('milestones');
 
     $dbh->do("ALTER TABLE milestones ADD UNIQUE (product_id, value)");
     $dbh->do("ALTER TABLE bugs DROP INDEX product");