summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <df@kahlann.erinye.com>2006-12-11 10:49:31 +0100
committerunknown <df@kahlann.erinye.com>2006-12-11 10:49:31 +0100
commitfb9d6963bf3a86741e70c69412476f5d0c4474c7 (patch)
treecdbfee3c72990385691eedd6c8a2d47b5378218f /mysql-test
parentd5e094d798a20c44d442c48061c9e314a26c20c4 (diff)
parent1a899c053188113f6057c9d1b7154eacad7b2e62 (diff)
downloadmariadb-git-fb9d6963bf3a86741e70c69412476f5d0c4474c7.tar.gz
Merge kahlann.erinye.com:/home/df/mysql/build/mysql-5.0
into kahlann.erinye.com:/home/df/mysql/build/mysql-5.0-build mysql-test/mysql-test-run.pl: Auto merged
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/lib/mtr_unique.pl12
1 files changed, 9 insertions, 3 deletions
diff --git a/mysql-test/lib/mtr_unique.pl b/mysql-test/lib/mtr_unique.pl
index a8fb320c773..3adc8413576 100644
--- a/mysql-test/lib/mtr_unique.pl
+++ b/mysql-test/lib/mtr_unique.pl
@@ -10,10 +10,16 @@ use Fcntl ':flock';
# Requested IDs are stored in a hash and released upon END.
#
my %mtr_unique_assigned_ids = ();
+my $mtr_unique_pid;
+BEGIN {
+ $mtr_unique_pid = $$ unless defined $mtr_unique_pid;
+}
END {
- while(my ($id,$file) = each(%mtr_unique_assigned_ids)) {
- print "Autoreleasing $file:$id\n";
- mtr_release_unique_id($file, $id);
+ if($mtr_unique_pid == $$) {
+ while(my ($id,$file) = each(%mtr_unique_assigned_ids)) {
+ print "Autoreleasing $file:$id\n";
+ mtr_release_unique_id($file, $id);
+ }
}
}