• Michael Widenius's avatar
    MDEV-5829: STOP SLAVE resets global status variables · dd13db6f
    Michael Widenius authored
    Reason for the bug was an optimization for higher connect speed where we moved when global status was updated,
    but forgot to update states when slave thread dies.
    Fixed by adding thd->add_status_to_global() before deleting slave thread's thd.
    
    
    mysys/my_delete.c:
      Added missing newline
    sql/mysqld.cc:
      Use add_status_to_global()
    sql/slave.cc:
      Added missing add_status_to_global()
    sql/sql_class.cc:
      Use add_status_to_global()
    sql/sql_class.h:
      Simplify adding local status to global by adding add_status_to_global()
    dd13db6f
rpl_000011.test 664 Bytes