Commit f7fb35c5 authored by ram@gw.mysql.r18.ru's avatar ram@gw.mysql.r18.ru

A fix (Bug #6843: Wrong function name crashes MySQL if mysql.proc table is missi

parent 6461d209
...@@ -981,6 +981,7 @@ sp_cache_functions(THD *thd, LEX *lex) ...@@ -981,6 +981,7 @@ sp_cache_functions(THD *thd, LEX *lex)
thd->lex= newlex; thd->lex= newlex;
newlex->proc_table= oldlex->proc_table; // hint if mysql.oper is opened newlex->proc_table= oldlex->proc_table; // hint if mysql.oper is opened
newlex->current_select= NULL;
name.m_name.str= strchr(name.m_qname.str, '.'); name.m_name.str= strchr(name.m_qname.str, '.');
name.m_db.length= name.m_name.str - name.m_qname.str; name.m_db.length= name.m_name.str - name.m_qname.str;
name.m_db.str= strmake_root(thd->mem_root, name.m_db.str= strmake_root(thd->mem_root,
......
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