mirror of
https://github.com/MariaDB/server.git
synced 2026-10-23 18:49:29 +03:00
n shutdown server could crash in case triggers executed during server run and some of triggers instructions were re-compiled. The crash is caused by attempt to allocate a memory for storing pointers on mem_roots used for memory allocation taken place on re-parsing failing trigger's statements. The reason of crash is dereferencing of nullptr returning by the function current_thd(). To fix the issue, use dummy THD on shutdown the table definition cache. tdc_start_shutdown() is solely invoked from the function clean_up() but the later is called from many places around the source code, not only from mysql_main(), particularly clean_up() is called from unireg_abort(). Therefore, the extra argument added into the signature of the function cleanup() to allow explicit request of use dummy THD on shutdown the table definition cache.
4.1 KiB
4.1 KiB