summaryrefslogtreecommitdiff
path: root/storage/xtradb/row/row0mysql.cc
diff options
context:
space:
mode:
Diffstat (limited to 'storage/xtradb/row/row0mysql.cc')
-rw-r--r--storage/xtradb/row/row0mysql.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/storage/xtradb/row/row0mysql.cc b/storage/xtradb/row/row0mysql.cc
index 59568f5c91b..9f1f216bccb 100644
--- a/storage/xtradb/row/row0mysql.cc
+++ b/storage/xtradb/row/row0mysql.cc
@@ -3614,9 +3614,15 @@ row_truncate_table_for_mysql(
} while (index);
mtr_start_trx(&mtr, trx);
- fsp_header_init(space_id,
+ bool ret = fsp_header_init(space_id,
FIL_IBD_FILE_INITIAL_SIZE, &mtr);
mtr_commit(&mtr);
+
+ if (!ret) {
+ table->file_unreadable = true;
+ err = DB_ERROR;
+ goto funct_exit;
+ }
}
} else {
/* Lock all index trees for this table, as we will