summaryrefslogtreecommitdiff
path: root/sql/sp_cache.cc
diff options
context:
space:
mode:
authorunknown <pem@mysql.comhem.se>2004-02-17 17:36:53 +0100
committerunknown <pem@mysql.comhem.se>2004-02-17 17:36:53 +0100
commite55c4ed179c5703f7b0c4b5ea2a4f9c6c59d0b20 (patch)
treeed911cc3b55e2fc5c450953efcdddc56c730097e /sql/sp_cache.cc
parent7444a50af81b2a790376519245fb09ca9a6068ba (diff)
downloadmariadb-git-e55c4ed179c5703f7b0c4b5ea2a4f9c6c59d0b20.tar.gz
WL#1366: Use the schema (db) associated with an SP.
Phase 1: Introduced sp_name class, for qualified name support. sql/item_func.cc: Introduced sp_name class; moved some methods from item_func.h. sql/item_func.h: Introduced sp_name class; moved some methods to item_func.cc. sql/sp.cc: Introduced sp_name class, for qualified name support. sql/sp.h: Introduced sp_name class, for qualified name support. sql/sp_cache.cc: Introduced sp_name class, for qualified name support. sql/sp_cache.h: Introduced sp_name class, for qualified name support. sql/sp_head.cc: Introduced sp_name class, for qualified name support. sql/sp_head.h: Introduced sp_name class, for qualified name support. sql/sql_lex.h: Introduced sp_name class, for qualified name support. sql/sql_parse.cc: Introduced sp_name class, for qualified name support. sql/sql_yacc.yy: Introduced sp_name class, for qualified name support.
Diffstat (limited to 'sql/sp_cache.cc')
-rw-r--r--sql/sp_cache.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/sp_cache.cc b/sql/sp_cache.cc
index 657a96ec33d..93f51938000 100644
--- a/sql/sp_cache.cc
+++ b/sql/sp_cache.cc
@@ -71,7 +71,7 @@ sp_cache_insert(sp_cache **cp, sp_head *sp)
}
sp_head *
-sp_cache_lookup(sp_cache **cp, char *name, uint namelen)
+sp_cache_lookup(sp_cache **cp, sp_name *name)
{
ulong v;
sp_cache *c= *cp;
@@ -89,11 +89,11 @@ sp_cache_lookup(sp_cache **cp, char *name, uint namelen)
c->version= v;
return NULL;
}
- return c->lookup(name, namelen);
+ return c->lookup(name->m_name.str, name->m_name.length);
}
bool
-sp_cache_remove(sp_cache **cp, char *name, uint namelen)
+sp_cache_remove(sp_cache **cp, sp_name *name)
{
sp_cache *c= *cp;
bool found= FALSE;
@@ -109,7 +109,7 @@ sp_cache_remove(sp_cache **cp, char *name, uint namelen)
if (c->version < v)
c->remove_all();
else
- found= c->remove(name, namelen);
+ found= c->remove(name->m_name.str, name->m_name.length);
c->version= v+1;
}
return found;