Use 'my_strnncoll_simple' instead of 'strncasecmp'

parent c2574de3
......@@ -3397,8 +3397,10 @@ int read_line(char *buf, int size)
DBUG_RETURN(0);
}
else if ((c == '{' &&
(!strncasecmp(buf, "while", min(5, p - buf)) ||
!strncasecmp(buf, "if", min(2, p - buf)))))
(!my_strnncoll_simple(charset_info, "while", 5,
buf, min(5, p - buf), 0) ||
!my_strnncoll_simple(charset_info, "if", 2,
buf, min(2, p - buf), 0))))
{
/* Only if and while commands can be terminated by { */
*p++= c;
......
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