summaryrefslogtreecommitdiff
path: root/sql/log_event.cc
diff options
context:
space:
mode:
authorunknown <knielsen@knielsen-hq.org>2013-03-22 11:26:28 +0100
committerunknown <knielsen@knielsen-hq.org>2013-03-22 11:26:28 +0100
commita3f651d0f635df1a29d152c7088150b3ba144b72 (patch)
tree66252c2b3443552793d623ace44b7385afcadfc3 /sql/log_event.cc
parentf1f9c4e4e580a7b060b0c9457afc2eaf7ad3e02d (diff)
downloadmariadb-git-a3f651d0f635df1a29d152c7088150b3ba144b72.tar.gz
MDEV-26: Global transaction ID.
Fix checksums for the new GTID events (reported by Pavel Ivanov). Fix printing of GTID_LIST_EVENT.
Diffstat (limited to 'sql/log_event.cc')
-rw-r--r--sql/log_event.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/sql/log_event.cc b/sql/log_event.cc
index b083a6eb2a4..04d1118b835 100644
--- a/sql/log_event.cc
+++ b/sql/log_event.cc
@@ -6126,6 +6126,7 @@ Gtid_log_event::Gtid_log_event(THD *thd_arg, uint64 seq_no_arg,
seq_no(seq_no_arg), domain_id(domain_id_arg),
flags2(standalone ? FL_STANDALONE : 0)
{
+ cache_type= Log_event::EVENT_NO_CACHE;
}
@@ -6354,6 +6355,7 @@ Gtid_list_log_event::Gtid_list_log_event(const char *buf, uint event_len,
Gtid_list_log_event::Gtid_list_log_event(rpl_binlog_state *gtid_set)
: count(gtid_set->count()), list(0)
{
+ cache_type= EVENT_NO_CACHE;
/* Failure to allocate memory will be caught by is_valid() returning false. */
if (count < (1<<28) &&
(list = (rpl_gtid *)my_malloc(count * sizeof(*list) + (count == 0),
@@ -6419,16 +6421,16 @@ Gtid_list_log_event::print(FILE *file, PRINT_EVENT_INFO *print_event_info)
uint32 i;
print_header(&cache, print_event_info, FALSE);
+ my_b_printf(&cache, "\tGtid list [");
for (i= 0; i < count; ++i)
{
longlong10_to_str(list[i].seq_no, buf, 10);
my_b_printf(&cache, "%u-%u-%s", list[i].domain_id,
list[i].server_id, buf);
if (i < count-1)
- my_b_printf(&cache, "\n# ");
- else
- my_b_printf(&cache, "\n");
+ my_b_printf(&cache, ",\n# ");
}
+ my_b_printf(&cache, "]\n");
}
}