summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorSachin Setiya <sachin.setiya@mariadb.com>2017-05-18 17:13:37 +0530
committerSachin Setiya <sachin.setiya@mariadb.com>2017-05-18 17:13:37 +0530
commitb5cdf01404dd352bb9aa7b58cad76f7a500b32d2 (patch)
tree8962525ed611fc9885bc9a738bda041dfdc4d32f /sql
parentefb9f2617bde1654006a99af625859eb509d5448 (diff)
downloadmariadb-git-b5cdf01404dd352bb9aa7b58cad76f7a500b32d2.tar.gz
MDEV-11092 Assertion `!writer.checksum_len || writer.remains == 0' failed
Problem:- This crash happens because logged stmt is quite big and while writing Annotate_rows_log_event it throws EFBIG error but we ignore this error and do not call cache_data->set_incident(). Solution:- When we normally write Binlog_log_event we check for error EFBIG, but we did do this for Annotate_rows_log_event. We check for this error and call cache_data->set_incident() accordingly. # Conflicts: # sql/log.cc
Diffstat (limited to 'sql')
-rw-r--r--sql/log.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/sql/log.cc b/sql/log.cc
index dc87c39730c..f8c256e645f 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -4887,13 +4887,20 @@ int THD::binlog_write_table_map(TABLE *table, bool is_transactional,
IO_CACHE *file=
cache_mngr->get_binlog_cache_log(use_trans_cache(this, is_transactional));
+ binlog_cache_data *cache_data=
+ cache_mngr->get_binlog_cache_data(use_trans_cache(this, is_transactional));
+
if (with_annotate && *with_annotate)
{
Annotate_rows_log_event anno(current_thd, is_transactional, false);
/* Annotate event should be written not more than once */
*with_annotate= 0;
if ((error= anno.write(file)))
+ {
+ if (my_errno == EFBIG)
+ cache_data->set_incident();
DBUG_RETURN(error);
+ }
}
if ((error= the_event.write(file)))
DBUG_RETURN(error);