mirror of
https://github.com/MariaDB/server.git
synced 2025-07-10 04:22:00 +03:00
Fixed memory leak when using histograms
This was introduced in last merge with 10.6 The reason is that 10.6 does not need anything special to free histograms as everything is allocated on a memroot. In 10.10 histograms is using the vector class, which has some problems: - No automatic free - No memory usage accounting (we should at some point remove vector usage because of the above problem) Fixed by expliciting freeing histograms when freeing TABLE_STATISTICS objects.
This commit is contained in:
@ -432,9 +432,9 @@ class Index_statistics;
|
||||
|
||||
class Table_statistics
|
||||
{
|
||||
|
||||
public:
|
||||
my_bool cardinality_is_null; /* TRUE if the cardinality is unknown */
|
||||
uint columns; /* Number of columns in table */
|
||||
ha_rows cardinality; /* Number of rows in the table */
|
||||
uchar *min_max_record_buffers; /* Record buffers for min/max values */
|
||||
Column_statistics *column_stats; /* Array of statistical data for columns */
|
||||
|
Reference in New Issue
Block a user