summaryrefslogtreecommitdiff
path: root/sql/sp_head.cc
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2016-06-14 13:55:28 +0200
committerSergei Golubchik <serg@mariadb.org>2016-06-14 13:55:28 +0200
commitae29ea2d86cd3fe5b2016baf595744cfb44c52cd (patch)
tree6f5017d7d25380d567084842e35015f52724e8d1 /sql/sp_head.cc
parent1b50d599606244677215fbe7b05be1a891fecf18 (diff)
parentef3f09f0c9e62ea1bf86b33b5d97e954b3ae34fe (diff)
downloadmariadb-git-ae29ea2d86cd3fe5b2016baf595744cfb44c52cd.tar.gz
Merge branch 'mysql/5.5' into 5.5
Diffstat (limited to 'sql/sp_head.cc')
-rw-r--r--sql/sp_head.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/sql/sp_head.cc b/sql/sp_head.cc
index 2cd627a2a32..019e9d9a478 100644
--- a/sql/sp_head.cc
+++ b/sql/sp_head.cc
@@ -1,6 +1,6 @@
/*
- Copyright (c) 2002, 2013, Oracle and/or its affiliates.
- Copyright (c) 2011, 2013, Monty Program Ab
+ Copyright (c) 2002, 2016, Oracle and/or its affiliates.
+ Copyright (c) 2011, 2016, MariaDB
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -480,8 +480,10 @@ sp_name::init_qname(THD *thd)
bool
check_routine_name(LEX_STRING *ident)
{
- if (!ident || !ident->str || !ident->str[0] ||
- ident->str[ident->length-1] == ' ')
+ DBUG_ASSERT(ident);
+ DBUG_ASSERT(ident->str);
+
+ if (!ident->str[0] || ident->str[ident->length-1] == ' ')
{
my_error(ER_SP_WRONG_NAME, MYF(0), ident->str);
return TRUE;