Commit 74f974e9 authored by Zardosht Kasheff's avatar Zardosht Kasheff Committed by Yoni Fogel

[t:4472], add table lock for truncate

git-svn-id: file:///svn/mysql/tokudb-engine/tokudb-engine@39739 c7de825b-a66e-492c-adef-691d508d4ae1
parent 96783a03
...@@ -7851,6 +7851,11 @@ int ha_tokudb::delete_all_rows() { ...@@ -7851,6 +7851,11 @@ int ha_tokudb::delete_all_rows() {
txn txn
); );
if (error) { goto cleanup; } if (error) { goto cleanup; }
error = share->key_file[i]->pre_acquire_table_lock(
share->key_file[i],
txn
);
if (error) { goto cleanup; }
} }
for (uint i = 0; i < curr_num_DBs; i++) { for (uint i = 0; i < curr_num_DBs; i++) {
error = truncate_dictionary(i, txn); error = truncate_dictionary(i, txn);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment