diff options
author | Alexander Nozdrin <alexander.nozdrin@oracle.com> | 2013-02-15 16:01:37 +0400 |
---|---|---|
committer | Alexander Nozdrin <alexander.nozdrin@oracle.com> | 2013-02-15 16:01:37 +0400 |
commit | 49b29688bb2c8b87ec38963eba679349d28ea48c (patch) | |
tree | ab92d502487e99eaa9eee704e24ac4d9aa73c43d /sql/sql_repl.cc | |
parent | d6fca3e346f566deeff49a3963d56f4b3e4b7d0a (diff) | |
download | mariadb-git-49b29688bb2c8b87ec38963eba679349d28ea48c.tar.gz |
Bug#16056537: MYSQLD CRASHES IN ITEM_FUNC_GET_USER_VAR::FIX_LENGTH_AND_DEC()
The technical problem was that THD::user_var_events_alloc was reset to NULL
from a valid value when a stored program is executed during the PREPARE statement.
The user visible problem was that the server crashed if user issued a PREPARE
statement using some combination of stored functions and user variables.
The fix is to restore THD::user_var_events_alloc to the original value.
This is a minimal fix for 5.5.
More proper patch has been already implemented for 5.6+. It avoids
evaluation of stored functions for the PREPARE phase.
From the user point of view, this bug is a regression, introduced by the patch for WL2649
(Number-to-string conversions), revid: bar@mysql.com-20100211041725-ijbox021olab82nv
However, the code resetting THD::user_var_events_alloc exists even in 5.1.
The WL just changed the way arguments are converted to strings and the bug became visible.
Diffstat (limited to 'sql/sql_repl.cc')
0 files changed, 0 insertions, 0 deletions