Skip to content
Browse files

Fix warning discovered by ASAN

Patch submitted by Eugene Kosov <>,
comments added by commiter.

Signed-off-by: Vicențiu Ciorbaru <>
  • Loading branch information...
kevgs authored and cvicentiu committed Jul 5, 2017
1 parent e555540 commit 4693f01f57406f86a26b7ccc605522dac6a9abb2
Showing with 5 additions and 2 deletions.
  1. +5 −2 sql/
@@ -349,10 +349,13 @@ int print_explain_row(select_result_sink *result,
item_list.push_back(new (mem_root) Item_string_sys(thd, jtype_str),

/* 'possible_keys' */
/* 'possible_keys'
The buffer must not be deallocated before we call send_data, otherwise
we may end up reading freed memory.
StringBuffer<64> possible_keys_buf;
if (possible_keys && !possible_keys->is_empty())
StringBuffer<64> possible_keys_buf;
push_string_list(thd, &item_list, *possible_keys, &possible_keys_buf);

0 comments on commit 4693f01

Please sign in to comment.
You can’t perform that action at this time.