X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FUID.pm;h=f5c4f6139102a0295860793abffa6ae188eb0e0c;hb=34687e57b8f651991a28cfc075a08fec67e7c6fe;hp=88d7338290fa59c732566aa26cf00b867b75e348;hpb=b4a403644cb80a612dd028882f971bdd20839275;p=freeside.git diff --git a/FS/FS/UID.pm b/FS/FS/UID.pm index 88d733829..f5c4f6139 100644 --- a/FS/FS/UID.pm +++ b/FS/FS/UID.pm @@ -4,6 +4,7 @@ use strict; use vars qw( @ISA @EXPORT_OK $cgi $dbh $freeside_uid $user $conf_dir $secrets $datasrc $db_user $db_pass %callback $driver_name + $AutoCommit ); use subs qw( getsecrets cgisetotaker @@ -21,6 +22,8 @@ $freeside_uid = scalar(getpwnam('freeside')); $conf_dir = "/usr/local/etc/freeside/"; +$AutoCommit = 1; #ours, not DBI + =head1 NAME FS::UID - Subroutines for database login and assorted other stuff @@ -75,9 +78,10 @@ sub adminsuidsetup { croak "Not running uid freeside!" unless checkeuid(); getsecrets; + $dbh->disconnect if $dbh; $dbh = DBI->connect($datasrc,$db_user,$db_pass, { - 'AutoCommit' => 'true', - 'ChopBlanks' => 'true', + 'AutoCommit' => 0, + 'ChopBlanks' => 1, } ) or die "DBI->connect error: $DBI::errstr\n"; swapuid(); #go to non-privledged user if running setuid freeside @@ -256,7 +260,7 @@ coderef into the hash %FS::UID::callback : =head1 VERSION -$Id: UID.pm,v 1.3 2000-06-23 12:25:59 ivan Exp $ +$Id: UID.pm,v 1.6 2001-04-23 09:00:06 ivan Exp $ =head1 BUGS