diff options
author | bell@sanja.is.com.ua <> | 2005-11-23 00:50:37 +0200 |
---|---|---|
committer | bell@sanja.is.com.ua <> | 2005-11-23 00:50:37 +0200 |
commit | 2bcd68973bb3ae278399a69b4642e76368edd31e (patch) | |
tree | bc5ba9cedbf44fad4c73c720d01700644e2e032e /mysql-test/r/trigger.result | |
parent | debff3e632f039bf3f0fd9bcd05c02218524a537 (diff) | |
download | mariadb-git-2bcd68973bb3ae278399a69b4642e76368edd31e.tar.gz |
Fix for BUG#13549 "Server crash with nested stored procedures
if inner routine has more local variables than outer one, and
one of its last variables was used as argument to NOT operator".
THD::spcont was non-0 when we were parsing stored routine/trigger
definition during execution of another stored routine. This confused
methods of Item_splocal and forced them use wrong runtime context.
Fix ensures that we always have THD::spcont equal to zero during
routine/trigger body parsing. This also allows to avoid problems
with errors which occur during parsing and SQL exception handlers.
Diffstat (limited to 'mysql-test/r/trigger.result')
-rw-r--r-- | mysql-test/r/trigger.result | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/r/trigger.result b/mysql-test/r/trigger.result index b305691fa18..73f498d4133 100644 --- a/mysql-test/r/trigger.result +++ b/mysql-test/r/trigger.result @@ -738,3 +738,17 @@ f1 1 drop trigger t1_bi; drop tables t1, t2; +create table t1 (a int); +drop procedure if exists p2; +CREATE PROCEDURE `p2`() +begin +insert into t1 values (1); +end// +create trigger trg before insert on t1 for each row +begin +declare done int default 0; +set done= not done; +end// +CALL p2(); +drop procedure p2; +drop table t1; |