From 9cf4dd44532ed7bd3111127eeb525e30a79db68a Mon Sep 17 00:00:00 2001 From: Jean-Marie RENOUARD Date: Fri, 29 Jun 2018 12:16:30 +0200 Subject: [PATCH] Ticket #383 Minor accessing undefined variable bug to fix eventually --- build/updateStaff.sh | 4 ++-- mysqltuner.pl | 10 ++++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/build/updateStaff.sh b/build/updateStaff.sh index 00cf77b..7a6e777 100644 --- a/build/updateStaff.sh +++ b/build/updateStaff.sh @@ -9,7 +9,7 @@ perltidy -b mysqltuner.pl echo "* Update CVE list" perl updateCVElist.pl -git add ../vulnerabilities.csv ../mysqltuner.pl ./USAGE.md +git add ../vulnerabilities.csv ../mysqltuner.pl ../USAGE.md git commit -m 'Update Vulnerabilities list Indenting mysqltuner -Update Usage information' \ No newline at end of file +Update Usage information' diff --git a/mysqltuner.pl b/mysqltuner.pl index 70c3f33..bb1fb1c 100755 --- a/mysqltuner.pl +++ b/mysqltuner.pl @@ -1778,7 +1778,8 @@ sub security_recommendations { if (@mysqlstatlist) { foreach my $line ( sort @mysqlstatlist ) { chomp($line); - badprint "User '" . $line . "' does not specify hostname restrictions."; + badprint "User '" . $line + . "' does not specify hostname restrictions."; } push( @generalrec, "Restrict Host for user\@% to user\@SpecificDNSorIp" ); @@ -1847,7 +1848,7 @@ sub get_replication_status { . " server(s)."; } infoprint "Binlog format: " . $myvar{'binlog_format'}; - infoprint "XA support enabled: " . $myvar{'innodb_support_xa'}; + infoprint "XA support enabled: " . defined($myvar{'innodb_support_xa'})?$myvar{'innodb_support_xa'}:'UNKONOWN'; infoprint "Semi synchronous replication Master: " . ( defined( $myvar{'rpl_semi_sync_master_enabled'} ) @@ -2664,7 +2665,7 @@ sub mysql_stats { $qps = sprintf( "%.3f", $mystat{'Questions'} / $mystat{'Uptime'} ); } push( @generalrec, - "MySQL was started within the last 24 hours - recommendations may be inaccurate" +"MySQL was started within the last 24 hours - recommendations may be inaccurate" ) if ( $mystat{'Uptime'} < 86400 ); infoprint "Up for: " . pretty_uptime( $mystat{'Uptime'} ) . " (" @@ -3412,7 +3413,8 @@ sub mysqsl_pfs { infoprint "Performance schema is disabled."; if ( mysql_version_ge( 5, 6 ) ) { push( @generalrec, - "Performance schema should be activated for better diagnostics" ); + "Performance schema should be activated for better diagnostics" + ); push( @adjvars, "performance_schema = ON enable PFS" ); } }