Description of problem: When a client without a reverse DNS entry is connected to the MySQL server, mytop displays an error message and doesn't show the client address. Version-Release number of selected component (if applicable): mytop-1.7-1.b737f60.fc12.noarch How reproducible: Always Steps to Reproduce: 1. Run mytop while a client without a reverse DNS entry is connection to the MySQL server. Actual results: The following message shows up in the middle of the output: Use of uninitialized value $host in substitution (s///) at /usr/bin/mytop line 958. The IP address of the client is replaced by an empty string. Expected results: The IP address of the client should be shown. Additional info: Here is a patch that fixes that problem. --- /usr/bin/mytop 2010-03-27 14:05:52.000000000 -0700 +++ /home/andreasg/bin/mytop 2010-05-05 15:15:54.000000000 -0700 @@ -955,8 +955,11 @@ { $thread->{Host} =~ s/:\d+$//; my $host = gethostbyaddr(inet_aton($thread->{Host}), AF_INET); - $host =~ s/^([^.]+).*/$1/; - $thread->{Host} = $host; + if (defined $host) + { + $host =~ s/^([^.]+).*/$1/; + $thread->{Host} = $host; + } } ## Fix possible undefs
mytop-1.7-3.b737f60.fc11 has been submitted as an update for Fedora 11. http://admin.fedoraproject.org/updates/mytop-1.7-3.b737f60.fc11
mytop-1.7-3.b737f60.fc13 has been submitted as an update for Fedora 13. http://admin.fedoraproject.org/updates/mytop-1.7-3.b737f60.fc13
mytop-1.7-3.b737f60.fc12 has been submitted as an update for Fedora 12. http://admin.fedoraproject.org/updates/mytop-1.7-3.b737f60.fc12
Thanks for report and patch.
mytop-1.7-3.b737f60.fc12 has been pushed to the Fedora 12 stable repository. If problems still persist, please make note of it in this bug report.
mytop-1.7-3.b737f60.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report.
mytop-1.7-3.b737f60.fc13 has been pushed to the Fedora 13 stable repository. If problems still persist, please make note of it in this bug report.