summaryrefslogtreecommitdiff
path: root/sql/sql_table.cc
diff options
context:
space:
mode:
author <Li-Bing.Song@sun.com>2010-03-28 16:37:47 +0800
committer <Li-Bing.Song@sun.com>2010-03-28 16:37:47 +0800
commit8d22c5f3efe4ab127cbe7bc3064b856e9f4849ff (patch)
treea813ba865f4d9d6b86ee3aa123046c8d65544830 /sql/sql_table.cc
parent8620be47e57e7ed19d364614c3da6e33a1ad4489 (diff)
downloadmariadb-git-8d22c5f3efe4ab127cbe7bc3064b856e9f4849ff.tar.gz
Bug #50095 Multi statement including CREATE EVENT causes rotten binlog entry
The log event of 'CREATE EVENT' was being binlogged with garbage at the end of the query if 'CREATE EVENT' is followed by another SQL statement and they were executed as one command. for example: DELIMITER |; CREATE EVENT e1 ON EVERY DAY DO SELECT 1; SELECT 'a'; DELIMITER ;| When binlogging 'CREATE EVENT', we always create a new statement with definer and write it into the log event. The new statement is made from cpp_buf(preprocessed buffer). which is not a c string(end with '\0'), but it is copied as a c string. In this patch, cpp_buf is copied with its length.
Diffstat (limited to 'sql/sql_table.cc')
0 files changed, 0 insertions, 0 deletions