diff --git a/config/ac_mysql.m4 b/config/ac_mysql.m4 index aca1fd2..094ba1c 100644 --- a/config/ac_mysql.m4 +++ b/config/ac_mysql.m4 @@ -21,7 +21,7 @@ AC_DEFUN([MYSQL_SRC_TEST], [ [ withval=`dir_resolve "$withval"` ac_mysql_source_dir="$withval" - HEADERS="include/my_dir.h include/mysql/plugin.h include/mysql.h include/mysql_version.h include/config.h include/my_config.h" + HEADERS="include/my_dir.h include/mysql/plugin.h include/mysql.h include/mysql_version.h include/my_config.h" for file in $HEADERS; do if ! test -r "$withval/$file"; then AC_MSG_ERROR([Failed to find required header file $file in $withval, check the path and make sure you've run './configure .... && cd include && make' in MySQL 5.1 sources dir or 'cmake . && make' in MySQL 5.5 sources dir.]) diff --git a/include/mysql_inc.h b/include/mysql_inc.h index b8956da..9fb1615 100644 --- a/include/mysql_inc.h +++ b/include/mysql_inc.h @@ -5,6 +5,11 @@ #define HAVE_CONFIG_H #endif +// Compatibility shim for older zlib versions +#if !defined(ZLIB_VERNUM) || ZLIB_VERNUM < 0x1290 +#define crc32_z(crc, buf, len) crc32((crc), (buf), (len)) +#endif + #define MYSQL_DYNAMIC_PLUGIN 1 #define MYSQL_SERVER 1 diff --git a/offset-extract/offset-extract.sh b/offset-extract/offset-extract.sh index 7dc1084..7e9fb49 100644 --- a/offset-extract/offset-extract.sh +++ b/offset-extract/offset-extract.sh @@ -75,7 +75,7 @@ else CONNECT_ATTRS='printf ", 0, 0, 0"' fi -if echo $MYVER | grep -P '^(5\.7|8\.0)' > /dev/null +if echo $MYVER | grep -P '^(5\.7|8\.4|8\.0)' > /dev/null then if echo $MYVER | grep -P '^5\.7\.8' > /dev/null then @@ -115,7 +115,7 @@ DA_STATUS="print_offset Diagnostics_area m_status" # 5.5, 5.6, 5.7, mariadb 10. DA_SQL_ERRNO="print_offset Diagnostics_area m_sql_errno" # 5.5, 5.6, mariadb 10.0 to 10.5 STMT_DA="print_offset THD m_stmt_da" # 5.6, 5.7, mariadb 10.0 to 10.5 -if echo $MYVER | grep -P '^(5\.7|8\.0)' > /dev/null +if echo $MYVER | grep -P '^(5\.7|8\.4|8\.0)' > /dev/null then DA_SQL_ERRNO="print_offset Diagnostics_area m_mysql_errno" elif echo $MYVER | grep -P '^(5\.6|10\.)' > /dev/null @@ -132,7 +132,7 @@ fi LEX_COMMENT="" VIEW_TABLES="" -if echo $MYVER | grep -P '^(8\.0)' > /dev/null +if echo $MYVER | grep -P '^(8\.4|8\.0)' > /dev/null then LEX_COMMENT='printf ", 0"' # TABLE_LIST struct was used in older versions of mysql, its replacement is Table_ref class diff --git a/src/audit_offsets.cc b/src/audit_offsets.cc index 0a66df5..ba113d1 100644 --- a/src/audit_offsets.cc +++ b/src/audit_offsets.cc @@ -81,6 +81,8 @@ const ThdOffsets thd_offsets_arr[] = const ThdOffsets thd_offsets_arr[] = { /* +++ MYSQL 64 OFFSETS GO HERE +++ */ + //offsets for: mysqld (8.4.4) + {"8.4.4","3561a47b597886dd313e01c38c15b71f", 9512, 9552, 5024, 6452, 1280, 0, 0, 32, 64, 160, 1368, 9652, 6072, 4328, 4336, 4340, 7736, 1592, 32, 8696, 8736, 8720, 13032, 140, 668, 344}, //offsets for: mysqld (8.0.41) {"8.0.41","e818c531909ed2f1bf78b7c125da947c", 9440, 9480, 4952, 6380, 1280, 0, 0, 32, 64, 160, 1368, 9580, 6000, 4248, 4256, 4260, 7664, 1576, 32, 8624, 8664, 8648, 12824, 140, 668, 320}, //offsets for: /usr/sbin/mysqld (8.0.40-commercial)