Bug#21042 mysql client segfaults on importing a mysqldump export

- Use strxnmov to protect the "buff" variable from overrun


client/mysql.cc:
  Use strxnmov to protect the "buff" variable from overrun
This commit is contained in:
unknown 2006-07-27 12:28:49 +02:00
parent 464cadc99d
commit a49144c8c9

View file

@ -2858,7 +2858,7 @@ com_connect(String *buffer, char *line)
bzero(buff, sizeof(buff));
if (buffer)
{
strmov(buff, line);
strxnmov(buff, sizeof(buff), line, NullS);
tmp= get_arg(buff, 0);
if (tmp && *tmp)
{