1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Fix for memory leak which was introduced by patch improving locking in SP.

Made mysql_make_view() to call destructor for st_lex_local objects before
throwing them away (this happens in case of error).


sql/sql_lex.h:
  Made LEX's destructor virtual to be able properly destroy objects
  of inherited classes (i.e. of st_lex_local).
sql/sql_view.cc:
  mysql_make_view():
    We should call destructor for st_lex_local object before throwing
    it away.
This commit is contained in:
unknown
2005-03-04 20:54:24 +03:00
parent b1095fb0cd
commit f76b64f540
2 changed files with 3 additions and 2 deletions

View File

@ -854,6 +854,7 @@ ok2:
err:
if (arena)
thd->restore_backup_item_arena(arena, &backup);
delete table->view;
table->view= 0; // now it is not VIEW placeholder
thd->lex= old_lex;
DBUG_RETURN(1);