summaryrefslogtreecommitdiff
path: root/sql/sp_head.cc
diff options
context:
space:
mode:
authormonty@mysql.com/narttu.mysql.fi <>2006-11-30 18:25:05 +0200
committermonty@mysql.com/narttu.mysql.fi <>2006-11-30 18:25:05 +0200
commit3d4095603952aca95892d55fb1ef435132de1197 (patch)
tree66e16346c4fdfa20f915fdf53ea1f9419c07331c /sql/sp_head.cc
parent0bee93e038edf9a70ffe9d10cd93883a3288802f (diff)
downloadmariadb-git-3d4095603952aca95892d55fb1ef435132de1197.tar.gz
Fixed portability issue in my_thr_init.c (was added in my last push)
Fixed compiler warnings (detected by VC++): - Removed not used variables - Added casts - Fixed wrong assignments to bool - Fixed wrong calls with bool arguments - Added missing argument to store(longlong), which caused wrong store method to be called.
Diffstat (limited to 'sql/sp_head.cc')
-rw-r--r--sql/sp_head.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/sql/sp_head.cc b/sql/sp_head.cc
index a06bfe28a6f..152bc87aead 100644
--- a/sql/sp_head.cc
+++ b/sql/sp_head.cc
@@ -444,9 +444,12 @@ sp_head::operator delete(void *ptr, size_t size)
sp_head::sp_head()
:Query_arena(&main_mem_root, INITIALIZED_FOR_SP),
m_flags(0), m_recursion_level(0), m_next_cached_sp(0),
- m_first_instance(this), m_first_free_instance(this), m_last_cached_sp(this),
m_cont_level(0)
{
+ m_first_instance= this;
+ m_first_free_instance= this;
+ m_last_cached_sp= this;
+
m_return_field_def.charset = NULL;
extern byte *
@@ -1648,7 +1651,7 @@ sp_head::execute_procedure(THD *thd, List<Item> *args)
Item_null *null_item= new Item_null();
if (!null_item ||
- nctx->set_variable(thd, i, (struct Item **)&null_item))
+ nctx->set_variable(thd, i, (Item **)&null_item))
{
err_status= TRUE;
break;
@@ -2789,7 +2792,7 @@ void
sp_instr_freturn::print(String *str)
{
/* freturn type expr... */
- if (str->reserve(UINT_MAX+8+32)) // Add some for the expr. too
+ if (str->reserve(1024+8+32)) // Add some for the expr. too
return;
str->qs_append(STRING_WITH_LEN("freturn "));
str->qs_append((uint)m_type);