summaryrefslogtreecommitdiff
path: root/sql/sp.cc
diff options
context:
space:
mode:
authorVladislav Vaintroub <wlad@mariadb.com>2017-09-19 17:45:17 +0000
committerVladislav Vaintroub <wlad@mariadb.com>2017-09-28 17:20:46 +0000
commiteba44874ca9fc317696630cb371623142289fa99 (patch)
treef67cd5dbcaf102abef2fb26f76357d14feaded04 /sql/sp.cc
parentde7c2e5e545df90fc9814c60a8a5a8d20f22b2c3 (diff)
downloadmariadb-git-eba44874ca9fc317696630cb371623142289fa99.tar.gz
MDEV-13844 : Fix Windows warnings. Fix DBUG_PRINT.
- Fix win64 pointer truncation warnings (usually coming from misusing 0x%lx and long cast in DBUG) - Also fix printf-format warnings Make the above mentioned warnings fatal. - fix pthread_join on Windows to set return value.
Diffstat (limited to 'sql/sp.cc')
-rw-r--r--sql/sp.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/sql/sp.cc b/sql/sp.cc
index a31b2a2cfc5..fcbf4dc43d4 100644
--- a/sql/sp.cc
+++ b/sql/sp.cc
@@ -1754,11 +1754,11 @@ sp_find_routine(THD *thd, stored_procedure_type type, sp_name *name,
String retstr(64);
retstr.set_charset(sp->get_creation_ctx()->get_client_cs());
- DBUG_PRINT("info", ("found: 0x%lx", (ulong)sp));
+ DBUG_PRINT("info", ("found:%p", sp));
if (sp->m_first_free_instance)
{
- DBUG_PRINT("info", ("first free: 0x%lx level: %lu flags %x",
- (ulong)sp->m_first_free_instance,
+ DBUG_PRINT("info", ("first free:%p level: %lu flags %x",
+ sp->m_first_free_instance,
sp->m_first_free_instance->m_recursion_level,
sp->m_first_free_instance->m_flags));
DBUG_ASSERT(!(sp->m_first_free_instance->m_flags & sp_head::IS_INVOKED));
@@ -1798,8 +1798,8 @@ sp_find_routine(THD *thd, stored_procedure_type type, sp_name *name,
new_sp->m_recursion_level= level;
new_sp->m_first_instance= sp;
sp->m_last_cached_sp= sp->m_first_free_instance= new_sp;
- DBUG_PRINT("info", ("added level: 0x%lx, level: %lu, flags %x",
- (ulong)new_sp, new_sp->m_recursion_level,
+ DBUG_PRINT("info", ("added level:%p, level: %lu, flags %x",
+ new_sp, new_sp->m_recursion_level,
new_sp->m_flags));
DBUG_RETURN(new_sp);
}
@@ -1810,8 +1810,8 @@ sp_find_routine(THD *thd, stored_procedure_type type, sp_name *name,
if (db_find_routine(thd, type, name, &sp) == SP_OK)
{
sp_cache_insert(cp, sp);
- DBUG_PRINT("info", ("added new: 0x%lx, level: %lu, flags %x",
- (ulong)sp, sp->m_recursion_level,
+ DBUG_PRINT("info", ("added new:%p, level: %lu, flags %x",
+ sp, sp->m_recursion_level,
sp->m_flags));
}
}