summaryrefslogtreecommitdiff
path: root/storage/perfschema
diff options
context:
space:
mode:
Diffstat (limited to 'storage/perfschema')
-rw-r--r--storage/perfschema/pfs_lock.h13
1 files changed, 1 insertions, 12 deletions
diff --git a/storage/perfschema/pfs_lock.h b/storage/perfschema/pfs_lock.h
index d253cfa4366..82c34fc2702 100644
--- a/storage/perfschema/pfs_lock.h
+++ b/storage/perfschema/pfs_lock.h
@@ -135,25 +135,14 @@ struct pfs_lock
*/
void allocated_to_free(void)
{
-#ifndef DBUG_OFF
- extern volatile bool ready_to_exit;
-#endif
-
/*
If this record is not in the ALLOCATED state and the caller is trying
to free it, this is a bug: the caller is confused,
and potentially damaging data owned by another thread or object.
The correct assert to use here to guarantee data integrity is simply:
DBUG_ASSERT(m_state == PFS_LOCK_ALLOCATED);
- Now, because of Bug#56666 (Race condition between the server main thread
- and the kill server thread), this assert actually fails during shutdown,
- and the failure is legitimate, on concurrent calls to mysql_*_destroy(),
- when destroying the instrumentation of an object ... twice.
- During shutdown this has no consequences for the performance schema,
- so the assert is relaxed with the "|| ready_to_exit" condition as a work
- around until Bug#56666 is fixed.
*/
- DBUG_ASSERT((m_state == PFS_LOCK_ALLOCATED) || ready_to_exit);
+ DBUG_ASSERT(m_state == PFS_LOCK_ALLOCATED);
PFS_atomic::store_32(&m_state, PFS_LOCK_FREE);
}