1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

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).
This commit is contained in:
Sergei Golubchik
2021-09-12 15:23:34 +02:00
parent 42e9506ce9
commit 1a6c130c4f

View File

@@ -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));
}