jon             Mon Apr  2 20:27:46 2001 EDT

  Modified files:              
    /php4/pear/DB       pgsql.php 
  Log:
  Make the 'protocol' DSN element optional.
  
  
Index: php4/pear/DB/pgsql.php
diff -u php4/pear/DB/pgsql.php:1.34 php4/pear/DB/pgsql.php:1.35
--- php4/pear/DB/pgsql.php:1.34 Wed Mar 28 15:52:21 2001
+++ php4/pear/DB/pgsql.php      Mon Apr  2 20:27:46 2001
@@ -79,8 +79,9 @@
     {
         $this->dsn = $dsninfo;
         $host = $dsninfo['hostspec'];
+        $protocol = (isset($dsninfo['protocol'])) ? $dsninfo['protocol'] : '';
         $connstr = '';
-        if (($host !== false) && ($dsninfo['protocol'] != 'unix')){
+        if (($host !== false) && ($protocol != 'unix')){
             if (($pos=strpos(':', $host)) !== false) {
                 $dbhost = substr($host, 0, $pos);
                 $port = substr($host, $pos+1);



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to