Commit 544d9632 authored by Bjorn Munch's avatar Bjorn Munch

Bug #52214 Misleading error msg when test fails before having produced any query

output
Print error message only if real error
parent 3c370c8c
......@@ -610,8 +610,11 @@ class LogFile {
if ((bytes= fread(buf, 1, sizeof(buf), m_file)) <= 0)
{
fprintf(stderr, "Failed to read from '%s', errno: %d\n",
m_file_name, errno);
// ferror=0 will happen here if no queries executed yet
if (ferror(m_file))
fprintf(stderr,
"Failed to read from '%s', errno: %d, feof:%d, ferror:%d\n",
m_file_name, errno, feof(m_file), ferror(m_file));
DBUG_VOID_RETURN;
}
......
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