diff options
author | pem@mysql.com <> | 2002-12-16 15:40:44 +0100 |
---|---|---|
committer | pem@mysql.com <> | 2002-12-16 15:40:44 +0100 |
commit | b1593c9a692141cadb345d5da6836e503f0e1dbf (patch) | |
tree | 6a965cec0f444a67ed29877855da3a7309f6dce5 /sql/sp_pcontext.cc | |
parent | 113b9240d1226c3934890144abfa9682cb4d8b8e (diff) | |
download | mariadb-git-b1593c9a692141cadb345d5da6836e503f0e1dbf.tar.gz |
Fixed the broken backpatching implementation.
Implemented IF-THEN-ELSE.
Diffstat (limited to 'sql/sp_pcontext.cc')
-rw-r--r-- | sql/sp_pcontext.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sql/sp_pcontext.cc b/sql/sp_pcontext.cc index 9dc995f582f..96296e54184 100644 --- a/sql/sp_pcontext.cc +++ b/sql/sp_pcontext.cc @@ -92,7 +92,7 @@ sp_pcontext::push(LEX_STRING *name, enum enum_field_types type, } } -void +sp_label_t * sp_pcontext::push_label(char *name, uint ip) { sp_label_t *lab = (sp_label_t *)my_malloc(sizeof(sp_label_t), MYF(MY_WME)); @@ -103,18 +103,21 @@ sp_pcontext::push_label(char *name, uint ip) lab->ip= ip; m_label.push_front(lab); } + return lab; } -void +sp_label_t * sp_pcontext::push_gen_label(uint ip) { + sp_label_t *lab= NULL; char *s= my_malloc(10, MYF(MY_WME)); // 10=... if (s) { sprintf(s, ".%08x", m_genlab++); // ...9+1 - push_label(s, ip); + lab= push_label(s, ip); } + return lab; } sp_label_t * |