Skip to content

Commit f5e0522

Browse files
committed
MDEV-10388 MariaDB 10.1.x keeps (deleted) ML* files in tmpdir after LOAD DATA completes
truncate unused IO_CACHE backing store files in binlog_cache_data to release the disk space they were occupying
1 parent 1d702ff commit f5e0522

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

sql/log.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,9 @@ class binlog_cache_data
263263
{
264264
compute_statistics();
265265
truncate(0);
266+
if(cache_log.file != -1)
267+
my_chsize(cache_log.file, 0, 0, MYF(MY_WME));
268+
266269
changes_to_non_trans_temp_table_flag= FALSE;
267270
incident= FALSE;
268271
before_stmt_pos= MY_OFF_T_UNDEF;

0 commit comments

Comments
 (0)