1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Merge 10.2 into 10.3

This commit is contained in:
Marko Mäkelä
2020-03-30 11:12:56 +03:00
70 changed files with 958 additions and 727 deletions

View File

@ -1,6 +1,6 @@
/*
Copyright (c) 2000, 2019, Oracle and/or its affiliates.
Copyright (c) 2010, 2019, MariaDB
Copyright (c) 2010, 2020, 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
@ -4327,8 +4327,14 @@ bool validate_comment_length(THD *thd, LEX_CSTRING *comment, size_t max_len,
uint err_code, const char *name)
{
DBUG_ENTER("validate_comment_length");
size_t tmp_len= my_charpos(system_charset_info, comment->str,
comment->str + comment->length, max_len);
if (comment->length == 0)
DBUG_RETURN(false);
if (max_len > comment->length)
max_len= comment->length;
size_t tmp_len=
Well_formed_prefix(system_charset_info, comment->str, max_len).length();
if (tmp_len < comment->length)
{
if (thd->is_strict_mode())