Uploaded image for project: 'Percona Server'
  1. Percona Server
  2. PS-4980

Valgrind: Syscall param write(buf) points to uninitialised byte(s): Event_encrypter::encrypt_and_write()

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: High
    • Resolution: Duplicate
    • Affects Version/s: 5.7
    • Fix Version/s: 5.7.24-26
    • Component/s: None
    • Labels:

      Description

      The following two MTR test cases generate

      Syscall param write(buf) points to uninitialised byte(s)
      

      Valgrind error

      rpl.rpl_bug72457_innodb
      rpl.rpl_bug72457_myisam
      
      ==89293== Thread 29:
      ==89293== Syscall param write(buf) points to uninitialised byte(s)
      ==89293==    at 0x63A02B7: write (write.c:27)
      ==89293==    by 0x1995684: my_write (my_write.c:63)
      ==89293==    by 0x196DE4A: inline_mysql_file_write (mysql_file.h:1187)
      ==89293==    by 0x197108E: _my_b_cache_write (mf_iocache.c:1490)
      ==89293==    by 0x1971987: my_b_flush_io_cache (mf_iocache.c:1699)
      ==89293==    by 0x196F1EE: _my_b_write (mf_iocache.c:536)
      ==89293==    by 0x196DC07: my_b_write (my_sys.h:538)
      ==89293==    by 0x197142D: my_b_safe_write (mf_iocache.c:1586)
      ==89293==    by 0x190880B: Event_encrypter::encrypt_and_write(st_io_cache*, unsigned char const*, unsigned long) (event_crypt.cc:103)
      ==89293==    by 0x189ACB7: Log_event::wrapper_my_b_safe_write(st_io_cache*, unsigned char const*, unsigned long) (log_event.cc:1018)
      ==89293==    by 0x18B9ECC: Rows_log_event::write_data_header(st_io_cache*) (log_event.cc:11899)
      ==89293==    by 0x18C588E: Log_event::write(st_io_cache*) (log_event.h:837)
      ==89293==    by 0x18D6AF6: binlog_cache_data::write_event(THD*, Log_event*) (binlog.cc:1406)
      ==89293==    by 0x18E6CB1: MYSQL_BIN_LOG::flush_and_set_pending_rows_event(THD*, Rows_log_event*, bool) (binlog.cc:7800)
      ==89293==    by 0x18F7E80: Rows_log_event* THD::binlog_prepare_pending_rows_event<Write_rows_log_event>(TABLE*, unsigned int, unsigned long, bool, Write_rows_log_event*, unsigned char const*) (binlog.cc:12003)
      ==89293==    by 0x18F1129: THD::binlog_write_row(TABLE*, bool, unsigned char const*, unsigned char const*) (binlog.cc:12161)
      ==89293==  Address 0x1a3ec5d0 is 18,224 bytes inside a block of size 32,800 alloc'd
      ==89293==    at 0x4C2FA3F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==89293==    by 0x198E2E9: my_raw_malloc (my_malloc.c:191)
      ==89293==    by 0x198DDE0: my_malloc (my_malloc.c:54)
      ==89293==    by 0x196E900: init_io_cache_ext (mf_iocache.c:327)
      ==89293==    by 0x196EBC7: init_io_cache (mf_iocache.c:391)
      ==89293==    by 0x196BAC8: open_cached_file (mf_cache.c:60)
      ==89293==    by 0x18EDBCD: THD::binlog_setup_trx_data() (binlog.cc:10536)
      ==89293==    by 0x18EDF77: binlog_start_trans_and_stmt(THD*, Log_event*) (binlog.cc:10643)
      ==89293==    by 0x18EE3C6: THD::binlog_write_table_map(TABLE*, bool, bool) (binlog.cc:10736)
      ==89293==    by 0xF8F55C: write_locked_table_maps(THD*) (handler.cc:8315)
      ==89293==    by 0xF8F791: binlog_log_row(TABLE*, unsigned char const*, unsigned char const*, bool (*)(THD*, TABLE*, bool, unsigned char const*, unsigned char const*)) (handler.cc:8384)
      ==89293==    by 0xF90098: handler::ha_write_row(unsigned char*) (handler.cc:8530)
      ==89293==    by 0x18573BF: write_record(THD*, TABLE*, COPY_INFO*, COPY_INFO*) (sql_insert.cc:1881)
      ==89293==    by 0x18541F1: Sql_cmd_insert::mysql_insert(THD*, TABLE_LIST*) (sql_insert.cc:773)
      ==89293==    by 0x185B2FA: Sql_cmd_insert::execute(THD*) (sql_insert.cc:3120)
      ==89293==    by 0x1605935: mysql_execute_command(THD*, bool) (sql_parse.cc:3767)
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                przemyslaw.skibinski Przemyslaw Skibinski
                Reporter:
                yura.sorokin Yura Sorokin
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: