• Andrei Elkin's avatar
    Bug #38240 Crash in safe_mutex_lock () thr_mutex.c line 97 on rotate_relay_log · 0ecf826a
    Andrei Elkin authored
                
    The reason for the crash was rotate_relay_log (mi=0x0) did not verify
    the passed value of active_mi.  There are more cases where active_mi
    is supposed to be non-zero e.g change_master(), stop_slave(), and it's
    reasonable to protect from a similar crash all of them with common
    fixes.
                
    Fixed with spliting end_slave() in slave threads release and slave
    data clean-up parts (a new close_active_mi()). The new function is
    invoked at the very end of close_connections() so that all users of
    active_mi are proven to have left.
    0ecf826a
slave.cc 146 KB