summaryrefslogtreecommitdiff
path: root/LedgerSMB
diff options
context:
space:
mode:
authortetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-04-09 15:56:05 +0000
committertetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-04-09 15:56:05 +0000
commit4a107c396ea720919e9fe3ebb5cb63d183abad86 (patch)
treecc458c8c496f5eb6c472027f0a2a264badbd9b87 /LedgerSMB
parentae576e96e56cdc3aaffb30e1305ada264efcace0 (diff)
Repoint backups to the correct database
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/branches/1.2@1042 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB')
-rwxr-xr-xLedgerSMB/AM.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/LedgerSMB/AM.pm b/LedgerSMB/AM.pm
index 8bcd10fb..737c8273 100755
--- a/LedgerSMB/AM.pm
+++ b/LedgerSMB/AM.pm
@@ -1617,7 +1617,7 @@ sub backup {
my $suffix = "";
if ($form->{media} eq 'email') {
- print OUT qx(PGPASSWORD="$globalDBPassword" pg_dump -U $globalDBUserName -h $globalDBhost -Fc -p $globalDBport $globalDBname);
+ print OUT qx(PGPASSWORD="$myconfig->{dbpasswd}" pg_dump -U $myconfig->{dbuser} -h $myconfig->{dbhost} -Fc -p $myconfig->{dbport} $myconfig->{dbname});
close OUT;
use LedgerSMB::Mailer;
$mail = new Mailer;
@@ -1644,7 +1644,7 @@ sub backup {
print OUT qq|Content-Type: application/file;\n| .
qq|Content-Disposition: attachment; filename="$myconfig->{dbname}-$form->{dbversion}-$t[5]$t[4]$t[3].sql$suffix"\n\n|;
- print OUT qx(PGPASSWORD="$globalDBPassword" pg_dump -U $globalDBUserName -h $globalDBhost -Fc -p $globalDBport $globalDBname);
+ print OUT qx(PGPASSWORD="$myconfig->{dbpasswd}" pg_dump -U $myconfig->{dbuser} -h $myconfig->{dbhost} -Fc -p $myconfig->{dbport} $myconfig->{dbname});
}
unlink "$tmpfile";