diff options
Diffstat (limited to 'sql/sql_test.cc')
-rw-r--r-- | sql/sql_test.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/sql_test.cc b/sql/sql_test.cc index 68d30d5fecb..a3506687a72 100644 --- a/sql/sql_test.cc +++ b/sql/sql_test.cc @@ -658,9 +658,12 @@ Memory allocated by threads: %s\n", void print_keyuse_array_for_trace(THD *thd, DYNAMIC_ARRAY *keyuse_array) { + DBUG_ASSERT(thd->trace_started()); + Json_writer_object wrapper(thd); Json_writer_array trace_key_uses(thd, "ref_optimizer_key_uses"); - for(uint i=0; i < keyuse_array->elements; i++) + + for (uint i=0; i < keyuse_array->elements; i++) { KEYUSE *keyuse= (KEYUSE*)dynamic_array_ptr(keyuse_array, i); Json_writer_object keyuse_elem(thd); |