mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
Stage 2 of MDEV-6152:
- Added mem_root to all calls to new Item - Added private method operator new(size_t size) to Item to ensure that we always use a mem_root when creating an item. This saves use once call to current_thd per Item creation
This commit is contained in:
@ -161,7 +161,8 @@ void Expression_cache_tmptable::init()
|
||||
goto error;
|
||||
}
|
||||
|
||||
if (!(cached_result= new Item_field(table_thd, cache_table->field[0])))
|
||||
if (!(cached_result= new (table_thd->mem_root)
|
||||
Item_field(table_thd, cache_table->field[0])))
|
||||
{
|
||||
DBUG_PRINT("error", ("Creating Item_field failed"));
|
||||
goto error;
|
||||
|
Reference in New Issue
Block a user