Bug#32661 - Compiler warning in client/mysql.cc

The initialization to zero via LINT_INIT made mysql.test fail.
print_warnings() was suppressed where it should not.

Fixed initialization so that it fakes warnings.
parent 6c6ee172
...@@ -2155,10 +2155,10 @@ com_go(String *buffer,char *line __attribute__((unused))) ...@@ -2155,10 +2155,10 @@ com_go(String *buffer,char *line __attribute__((unused)))
{ {
char buff[200], time_buff[32], *pos; char buff[200], time_buff[32], *pos;
MYSQL_RES *result; MYSQL_RES *result;
ulong timer, warnings; ulong timer;
ulong warnings= 1; /* Pre-initialize. See Bug #32661. */
uint error= 0; uint error= 0;
int err= 0; int err= 0;
LINT_INIT(warnings);
interrupted_query= 0; interrupted_query= 0;
if (!status.batch) if (!status.batch)
......
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