Skip to content

Commit 936f04c

Browse files
aquilamacedodr-m
authored andcommitted
MDEV-34195 tests: avoid LP64 MYSQL size assert on x32
x32 defines __x86_64__ but uses the ILP32 ABI, so the LP64 sizeof(MYSQL) == 1272 compile-time assert is selected incorrectly and breaks the build. Guard the x86_64 check with !defined(__ILP32__) so the LP64 size assert only applies to real amd64 LP64 builds, while leaving the existing Windows amd64 and i386 checks unchanged.
1 parent 612f4e2 commit 936f04c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tests/mysql_client_fw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1440,7 +1440,7 @@ int main(int argc, char **argv)
14401440
*/
14411441
#if defined _M_AMD64
14421442
compile_time_assert(sizeof(MYSQL) == 1208);
1443-
#elif defined __x86_64__
1443+
#elif defined(__x86_64__) && !defined(__ILP32__)
14441444
compile_time_assert(sizeof(MYSQL) == 1272);
14451445
#elif defined __i386__
14461446
compile_time_assert(sizeof(MYSQL) == 964);

0 commit comments

Comments
 (0)