Commit 1bdd8a62 authored by unknown's avatar unknown

Bug#13487 Japanese data inside a comment causes the syntax error

mysql.cc:
  Fixed not to copy multibyte characters to the
  target string if we are inside a comment.


client/mysql.cc:
  Bug#13487 Japanese data inside a comment causes the syntax error
  Fixed not to copy multibyte characters to the
  target string if we are inside a comment.
  ,
parent 0559f1e0
...@@ -1157,11 +1157,17 @@ static bool add_line(String &buffer,char *line,char *in_string, ...@@ -1157,11 +1157,17 @@ static bool add_line(String &buffer,char *line,char *in_string,
#ifdef USE_MB #ifdef USE_MB
int l; int l;
if (use_mb(charset_info) && if (use_mb(charset_info) &&
(l = my_ismbchar(charset_info, pos, strend))) { (l= my_ismbchar(charset_info, pos, strend)))
while (l--) {
*out++ = *pos++; if (!*ml_comment)
pos--; {
continue; while (l--)
*out++ = *pos++;
pos--;
}
else
pos+= l - 1;
continue;
} }
#endif #endif
if (!*ml_comment && inchar == '\\') if (!*ml_comment && inchar == '\\')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment