small patch for uds-driven PgSQL

Joe Marcus Clarke marcus at marcuscom.com
Sat Jan 15 21:08:31 EST 2011


On 1/13/11 10:04 AM, Dmitry Morozovsky wrote:
> Dear colleagues,
> 
> the following simple patch allows tb to work with PostgreSQL on local machine 
> without TCP socket (over unix-domain socket): just define db_host as empty.

A similar diff existed in HEAD.  I've merged it.

Joe

> 
> --- ./lib/Tinderbox/TinderboxDS.pm.orig 2009-11-27 20:32:31.000000000 +0300
> +++ ./lib/Tinderbox/TinderboxDS.pm      2011-01-13 18:03:08.000000000 +0300
> @@ -83,7 +83,8 @@
>                  $DBI_TYPE = 'database';
>          }
> 
> -        my $dsn = "DBI:$DB_DRIVER:$DBI_TYPE=$DB_NAME;host=$DB_HOST";
> +        my $dsn = "DBI:$DB_DRIVER:$DBI_TYPE=$DB_NAME";
> +       $dsn .= ";host=$DB_HOST" if $DB_HOST;
> 
>          $self->{'dbh'} =
>                 DBI->connect($dsn, $DB_USER, $DB_PASS, {PrintError => 0})
> 
> 


-- 
PGP Key : http://www.marcuscom.com/pgp.asc


More information about the tinderbox-list mailing list