Bug #12512 "show mysqld log" displays wrong last character in the file
Submitted: 11 Aug 2005 1:40 Modified: 11 Aug 2005 12:52
Reporter: Petr Chardin Email Updates:
Status: Not a Bug Impact on me:
None 
Category:Instance Manager Severity:S3 (Non-critical)
Version: OS:
Assigned to: Petr Chardin CPU Architecture:Any

[11 Aug 2005 1:40] Petr Chardin
Description:
IM displays log file content incorrectly, as it tries to read the eof character. Usually it is treated as newline. Because IM thinks that eof is a character it shows all info from the file shifted on one char. E.g.:

mysql> show mysqld log general 1;
+------+
| Log  |
+------+
| 
    |
+------+

How to repeat:
issue the above command

Suggested fix:
Don't read eof to the buffer.
[11 Aug 2005 2:11] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/internals/28140
[11 Aug 2005 12:52] Petr Chardin
IM displays newline as it should, since it is actually present in the file. I was confused by
vi, which doesn't show the last newline :)