summaryrefslogtreecommitdiff
path: root/sql/sp_head.cc
diff options
context:
space:
mode:
authorunknown <kent@mysql.com>2005-08-26 14:32:38 +0200
committerunknown <kent@mysql.com>2005-08-26 14:32:38 +0200
commitc8e160623366bab9722bed71354d3653b0cfbc09 (patch)
tree16de00dceb3c9f150bda29fffcab0e3c52e395b3 /sql/sp_head.cc
parentab161754f591371eba2868bfa03977bcbe5b6d7e (diff)
parent7e21963621f57e94e83fa2d4c633e7ca3124870b (diff)
downloadmariadb-git-c8e160623366bab9722bed71354d3653b0cfbc09.tar.gz
Merge mysql.com:/Users/kent/mysql/bk/mysql-5.0-release
into mysql.com:/Users/kent/mysql/bk/mysql-5.0 configure.in: Auto merged sql/sp_head.cc: Auto merged
Diffstat (limited to 'sql/sp_head.cc')
-rw-r--r--sql/sp_head.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/sql/sp_head.cc b/sql/sp_head.cc
index 24db71a8b11..7cb2bb79cf4 100644
--- a/sql/sp_head.cc
+++ b/sql/sp_head.cc
@@ -687,8 +687,12 @@ static bool subst_spvars(THD *thd, sp_instr *instr, LEX_STRING *query_str)
/* Find all instances of item_splocal used in this statement */
for (Item *item= instr->free_list; item; item= item->next)
{
- if (item->is_splocal() && ((Item_splocal*)item)->pos_in_query)
- sp_vars_uses.append((Item_splocal*)item);
+ if (item->is_splocal())
+ {
+ Item_splocal *item_spl= (Item_splocal*)item;
+ if (item_spl->pos_in_query)
+ sp_vars_uses.append(item_spl);
+ }
}
if (!sp_vars_uses.elements())
DBUG_RETURN(0);