From 1a6c130c4f157434e2272bacb680efa89eb4955e Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Sun, 12 Sep 2021 15:23:34 +0200 Subject: perfschema: use correct type for left shifts set_item() uses 1UL << bit, so is_set_item() must do the same. This fixes sporadic perfschema.show_aggregate failures (sporadic, because `bit` is the thread id, so depending on how many tests were run before perfschema.show_aggregate it can be above or below 32). --- storage/perfschema/pfs_engine_table.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/storage/perfschema/pfs_engine_table.cc b/storage/perfschema/pfs_engine_table.cc index 22ed3132c6b..c0b91cbb3b0 100644 --- a/storage/perfschema/pfs_engine_table.cc +++ b/storage/perfschema/pfs_engine_table.cc @@ -226,7 +226,7 @@ bool PFS_table_context::is_item_set(ulong n) { ulong word= n / m_word_size; ulong bit= n % m_word_size; - return (m_map[word] & (1 << bit)); + return (m_map[word] & (1UL << bit)); } -- cgit v1.2.1