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

Fix 'tee' command in mysql client. (Bug #8499)

client/mysql.cc:
  A va_list can't be reused without being copied or reset, so
  don't try to reuse it in tee_fprintf().
This commit is contained in:
unknown
2005-03-15 16:37:05 -08:00
parent e656fba778
commit 5ed4fd6ba9

View File

@ -3073,9 +3073,14 @@ void tee_fprintf(FILE *file, const char *fmt, ...)
#ifdef OS2
fflush( file);
#endif
if (opt_outfile)
(void) vfprintf(OUTFILE, fmt, args);
va_end(args);
if (opt_outfile)
{
va_start(args, fmt);
(void) vfprintf(OUTFILE, fmt, args);
va_end(args);
}
}