--- accounts_old.cgi	2008-11-11 01:26:11.000000000 +0100
+++ accounts.cgi	2011-07-17 23:16:23.255010198 +0200
@@ -22,18 +22,19 @@
 
 use strict;
 use warnings;
+use diagnostics;
 
 # Variables which you may need to change to match your installation
 # Changes to existing variables are NOT required to be published.
 
-my $box_dir = "/etc/box";
+my $box_dir = "/etc/boxbackup";
 my $bbstored_dir = "$box_dir/bbstored";
-my $ca_dir = "/mnt/backup/boxbackup/ca";
+my $ca_dir = "$box_dir/ca";
 
 # You should not need to change these unless you have a non-standard installation
 
 my $bbstored_conf_file = "$box_dir/bbstored.conf";
-my $bbstoreaccounts = "/usr/local/sbin/bbstoreaccounts";
+my $bbstoreaccounts = "/usr/sbin/bbstoreaccounts";
 my $accounts_db_file = undef;
 # my $accounts_db_file = "/etc/box/bbstored/accounts.txt";
 my $raidfile_conf_file = undef;
@@ -147,7 +148,7 @@
 
 check_access($bbstored_conf_file, "BBStoreD configuration file");
 
-my $bbstored_conf = Config::Scoped->new(file => $bbstored_conf_file)->parse();
+my $bbstored_conf = Config::Scoped->new(file => $bbstored_conf_file, warnings => 'off' )->parse();
 
 $accounts_db_file ||= $bbstored_conf->{'Server'}{'AccountDatabase'};
 die "Missing AccountDatabase in $bbstored_conf_file" unless $accounts_db_file;
@@ -336,7 +337,8 @@
 	$cgi->th('Used'),		$cgi->th('%'),
 	$cgi->th('Old files'),		$cgi->th('%'),
 	$cgi->th('Deleted files'),	$cgi->th('%'),
-	$cgi->th('Directories'),	$cgi->th('%'),
+	#$cgi->th('Directories'),	$cgi->th('%'),
+        $cgi->th('# Directories'),
 	$cgi->th('Soft limit'),		$cgi->th('%'),
 	$cgi->th('Hard limit'),
 	$cgi->th('Actions')
@@ -450,7 +452,8 @@
 		format_account_info($account_info->{'Used'}),
 		format_account_info($account_info->{'Old files'}),
 		format_account_info($account_info->{'Deleted files'}),
-		format_account_info($account_info->{'Directories'}),
+		#format_account_info($account_info->{'Directories'}),
+		$cgi->td($account_info->{'Directories'}),
 		format_account_info($account_info->{'Soft limit'}),
 		$cgi->td(human_format($account_info->{'Hard limit'}[0])),
 		$cgi->td($cgi->a({-href=>url($cgi, account=>$i)},
@@ -460,8 +463,11 @@
 
 print $cgi->end_table();
 
-my $account_no = $cgi->param("account");
+my $account_no = undef;
+if( $cgi->param("account")) {
+$account_no = $cgi->param("account");
 $account_no =~ tr/0-9a-fA-F//cd;
+}
 
 if (not $cgi->param("showcreate"))
 {
