• Jon Olav Hauglid's avatar
    Bug #54117 crash in thr_multi_unlock, temporary table · 60edcf94
    Jon Olav Hauglid authored
    This crash occured after ALTER TABLE was used on a temporary
    transactional table locked by LOCK TABLES. Any later attempts to
    execute LOCK/UNLOCK TABLES, caused the server to crash.
    
    The reason for the crash was the list of locked tables would
    end up having a pointer to a free'd table instance. This happened
    because ALTER TABLE deleted the table without also removing the
    table reference from the locked tables list.
    
    This patch fixes the problem by making sure ALTER TABLE also
    removes the table from the locked tables list.
    
    Test case added to innodb_mysql.test.
    60edcf94
innodb_mysql.test 19.9 KB