summaryrefslogtreecommitdiff
path: root/mysys/waiting_threads.c
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mysql.com>2008-11-10 20:11:27 +0100
committerSergei Golubchik <serg@mysql.com>2008-11-10 20:11:27 +0100
commit4f91e0726680b98898db16f8920420dde9d17ed8 (patch)
tree7fe5d09ec11879c573d36598bd7f96a356e5e4a0 /mysys/waiting_threads.c
parent89ad11ae8fe08eb9a552647e868fbad84622726b (diff)
downloadmariadb-git-4f91e0726680b98898db16f8920420dde9d17ed8.tar.gz
compile_time_assert
Diffstat (limited to 'mysys/waiting_threads.c')
-rw-r--r--mysys/waiting_threads.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mysys/waiting_threads.c b/mysys/waiting_threads.c
index edabc25ee51..14b1d639d00 100644
--- a/mysys/waiting_threads.c
+++ b/mysys/waiting_threads.c
@@ -396,6 +396,8 @@ void wt_thd_destroy(WT_THD *thd)
*/
int wt_resource_id_memcmp(void *a, void *b)
{
+ /* we use the fact that there's no padding in the middle of WT_RESOURCE_ID */
+ compile_time_assert(offsetof(WT_RESOURCE_ID, type) == sizeof(ulonglong));
return memcmp(a, b, sizeof_WT_RESOURCE_ID);
}