From a63596c87c085791e3c1b1f7435c26fb739b1fe3 Mon Sep 17 00:00:00 2001 From: kkalev Date: Sun, 29 Feb 2004 12:16:17 +0000 Subject: [PATCH] * Add a patch from Neil McCalden to not put spaces in the -p argument to the mysql binary. * Fix a bug in conf/config.php3. Patch from Neil McCalden --- Changelog | 2 ++ bin/monthly_tot_stats | 2 +- bin/tot_stats | 2 +- conf/config.php3 | 3 +-- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Changelog b/Changelog index 6e6bfc3..073b87e 100644 --- a/Changelog +++ b/Changelog @@ -6,6 +6,8 @@ Ver 1.68: * In log_badlogins for multiple logins if it is a mppp attempt, log it * Add a message when adding a user in the badusers table * Close sql connections in add_badusers.php3 +* Add a patch from Neil McCalden to not put spaces in the -p argument to the mysql binary. +* Fix a bug in conf/config.php3. Patch from Neil McCalden Ver 1.65: * Add a captions.conf file with a few configurable captions for now * Move the nas list to a separate file called naslist.conf diff --git a/bin/monthly_tot_stats b/bin/monthly_tot_stats index 5385720..79a976e 100755 --- a/bin/monthly_tot_stats +++ b/bin/monthly_tot_stats @@ -26,7 +26,7 @@ close CONF; die "sql_command directive is not set in admin.conf\n" if ($mysql eq ''); die "Could not find mysql binary. Please make sure that the \$mysql variable points to the right location\n" if (! -x $mysql); -$sql_password = ($sql_password == '') ? '' : "-p $sql_password"; +$sql_password = ($sql_password == '') ? '' : "-p$sql_password"; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime; if ($mday == 1){ diff --git a/bin/tot_stats b/bin/tot_stats index 2b38881..ca4149b 100755 --- a/bin/tot_stats +++ b/bin/tot_stats @@ -26,7 +26,7 @@ close CONF; die "sql_command directive is not set in admin.conf\n" if ($mysql eq ''); die "Could not find mysql binary. Please make sure that the \$mysql variable points to the right location\n" if (! -x $mysql); -$sql_password = ($sql_password == '') ? '' : "-p $sql_password"; +$sql_password = ($sql_password == '') ? '' : "-p$sql_password"; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime; $date_start = POSIX::strftime("%Y-%m-%d %T",0,0,0,($mday - 1),$mon,$year,$wday,$yday,$isdst); diff --git a/conf/config.php3 b/conf/config.php3 index eb8ccce..42fc005 100644 --- a/conf/config.php3 +++ b/conf/config.php3 @@ -44,8 +44,7 @@ if (!isset($config)){ $val=$config[$matches[1]]; $v=preg_replace("/%\{$matches[1]\}/",$val,$v); } - else - $config["$key"]="$v"; + $config["$key"]="$v"; } } if ($use_session) -- 2.39.5