-
Alexey Kopytov authored
The --hexdump option crashed mysqlbinlog when used together with the --read-from-remote-server option due to use of uninitialized memory. Since Log_event::print_header() relies on temp_buf to be initialized when the --hexdump option is present, dump_remote_log_entries() was fixed to setup temp_buf to point to the start of a binlog event as done in dump_local_log_entries(). The root cause of this bug is identical to the one for bug #17654. The latter was fixed in 5.1 and up, so this patch is backport of the patches for bug #17654 to 5.0. Only 5.0 needs a changelog entry. client/mysqlbinlog.cc: Fixed dump_remote_log_entries() so that temp_buf is initialized as it may be used later by Log_event::print_header() if the --hexdump option is present. mysql-test/r/mysqlbinlog.result: Added a test case for bug #41943. mysql-test/t/mysqlbinlog.test: Added a test case for bug #41943.
c0cd2742