diff options
author | Sergei Golubchik <serg@mariadb.org> | 2017-08-11 13:58:32 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2017-08-24 01:05:48 +0200 |
commit | 828602356cb080046c72b5b48e78efde7d0e958a (patch) | |
tree | 1a053eb65fb5b9ef55b70338af6549e18192d5ee /plugin/simple_password_check | |
parent | a6e215f221b1ed71eba2f313fb0102647d84f854 (diff) | |
download | mariadb-git-828602356cb080046c72b5b48e78efde7d0e958a.tar.gz |
Don't include my_global.h in "pure" plugins
this partially reverts 6e56ebbb498
Diffstat (limited to 'plugin/simple_password_check')
-rw-r--r-- | plugin/simple_password_check/simple_password_check.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/plugin/simple_password_check/simple_password_check.c b/plugin/simple_password_check/simple_password_check.c index 60d8a9ea815..dd4051e8169 100644 --- a/plugin/simple_password_check/simple_password_check.c +++ b/plugin/simple_password_check/simple_password_check.c @@ -14,13 +14,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#include <my_global.h> -#include <my_sys.h> #include <mysqld_error.h> #include <mysql/plugin_password_validation.h> #include <ctype.h> #include <string.h> -#include <my_attribute.h> static unsigned min_length, min_digits, min_letters, min_others; @@ -53,19 +50,17 @@ static int validate(MYSQL_CONST_LEX_STRING *username, others < min_others; } -static void fix_min_length(MYSQL_THD thd __attribute__((unused)), - struct st_mysql_sys_var *var __attribute__((unused)), +static void fix_min_length(MYSQL_THD thd, struct st_mysql_sys_var *var, void *var_ptr, const void *save) { - uint new_min_length; + unsigned int new_min_length; *((unsigned int *)var_ptr)= *((unsigned int *)save); new_min_length= min_digits + 2 * min_letters + min_others; if (min_length < new_min_length) { my_printf_error(ER_TRUNCATED_WRONG_VALUE, "Adjusted the value of simple_password_check_minimal_length " - "from %u to %u", ME_JUST_WARNING, - min_length, new_min_length); + "from %u to %u", ME_WARNING, min_length, new_min_length); min_length= new_min_length; } } |