mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
query_id and my_xid -> ulonglong
fix for binlog+autocommit+tclog comments, style fixes libmysqld/libmysqld.rc: Change mode to -rw-rw-r-- libmysqld/resource.h: Change mode to -rw-rw-r-- configure.in: check for getpagesize include/my_global.h: typo ? include/my_pthread.h: bug in thread_safe_decrement_and_test() mysql-test/r/bdb.result: results updated mysql-test/r/innodb.result: results updated mysql-test/r/mix_innodb_myisam_binlog.result: results updated mysql-test/r/rpl_relayrotate.result: results updated sql/ha_berkeley.cc: style fixes sql/ha_innodb.cc: fixes to follow innodb coding style sql/handler.cc: more comments. XA COMMIT ONE PHASE fix. sql/handler.h: my_xid -> ulonglong. comments sql/item_func.cc: DO RELEASE_LOCK("...") is no cache_stmt sql/log.cc: comments, better error messages sql/log_event.cc: even in autocommit mode we may need to cache_stmt xid is ulonglong sql/log_event.h: more comments. sql/mysql_priv.h: query_id is ulonglong sql/mysqld.cc: default value for --log-tc changed sql/share/errmsg.txt: better error messages sql/sql_class.h: cleanup, comments sql/sql_delete.cc: deleting from temporary tables is not always transactional sql/sql_insert.cc: insert into temporary table is not always transactional sql/sql_load.cc: load data into temp table is not always transactional sql/sql_parse.cc: comments. bad merge fixed. xa_state_names[] sql/sql_table.cc: create/drop temp table is not always transactional sql/sql_update.cc: update temp table is not always transactional
This commit is contained in:
@ -195,7 +195,7 @@ enum row_type { ROW_TYPE_NOT_USED=-1, ROW_TYPE_DEFAULT, ROW_TYPE_FIXED,
|
||||
#define HA_CREATE_USED_COMMENT (1L << 16)
|
||||
#define HA_CREATE_USED_PASSWORD (1L << 17)
|
||||
|
||||
typedef ulong my_xid;
|
||||
typedef ulonglong my_xid;
|
||||
#define MYSQL_XID_PREFIX "MySQLXid"
|
||||
#define MYSQL_XID_PREFIX_LEN 8 // must be a multiple of 8
|
||||
#define MYSQL_XID_OFFSET (MYSQL_XID_PREFIX_LEN+sizeof(server_id))
|
||||
@ -215,11 +215,11 @@ struct xid_t {
|
||||
bool eq(long g, long b, const char *d)
|
||||
{ return g == gtrid_length && b == bqual_length && !memcmp(d, data, g+b); }
|
||||
void set(LEX_STRING *l) { set(l->length, 0, l->str); }
|
||||
void set(ulong l)
|
||||
void set(ulonglong l)
|
||||
{
|
||||
set(MYSQL_XID_PREFIX_LEN, 0, MYSQL_XID_PREFIX);
|
||||
*(ulong*)(data+MYSQL_XID_PREFIX_LEN)=server_id;
|
||||
*(ulong*)(data+MYSQL_XID_OFFSET)=l;
|
||||
*(my_xid*)(data+MYSQL_XID_OFFSET)=l;
|
||||
gtrid_length=MYSQL_XID_GTRID_LEN;
|
||||
}
|
||||
void set(long g, long b, const char *d)
|
||||
@ -233,7 +233,7 @@ struct xid_t {
|
||||
void null() { formatID= -1; }
|
||||
my_xid quick_get_my_xid()
|
||||
{
|
||||
return *(ulong*)(data+MYSQL_XID_OFFSET);
|
||||
return *(my_xid*)(data+MYSQL_XID_OFFSET);
|
||||
}
|
||||
my_xid get_my_xid()
|
||||
{
|
||||
@ -319,8 +319,11 @@ typedef struct
|
||||
|
||||
typedef struct st_thd_trans
|
||||
{
|
||||
/* number of entries in the ht[] */
|
||||
uint nht;
|
||||
/* true is not all entries in the ht[] support 2pc */
|
||||
bool no_2pc;
|
||||
/* storage engines that registered themselves for this transaction */
|
||||
handlerton *ht[MAX_HA];
|
||||
} THD_TRANS;
|
||||
|
||||
|
Reference in New Issue
Block a user