mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
Bug #29687 mysql_stmt_store_result memory leak in libmysqld
In embedded server we use result->alloc to store field data for the result, but we didn't clean the result->alloc if the query returned an empty recordset. Cleaning for the empty recordset enabled libmysql/libmysql.c: Bug #29687 mysql_stmt_store_result memory leak in libmysqld we should clean result->alloc even if we have nothin in 'data' field
This commit is contained in:
parent
85603b2e0b
commit
9917ce268d
1 changed files with 1 additions and 1 deletions
|
|
@ -4945,7 +4945,7 @@ static my_bool reset_stmt_handle(MYSQL_STMT *stmt, uint flags)
|
|||
Reset stored result set if so was requested or it's a part
|
||||
of cursor fetch.
|
||||
*/
|
||||
if (result->data && (flags & RESET_STORE_RESULT))
|
||||
if (flags & RESET_STORE_RESULT)
|
||||
{
|
||||
/* Result buffered */
|
||||
free_root(&result->alloc, MYF(MY_KEEP_PREALLOC));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue