From: Stig Bakken Date: Wed, 18 Apr 2001 23:03:18 +0000 (+0000) Subject: * fix handling of broken DSNs like Colin suggested X-Git-Tag: php-4.0.6RC1~378 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b16f38e2e77752b99bb12b18a5148fc36c5621e8;p=php * fix handling of broken DSNs like Colin suggested --- diff --git a/pear/DB.php b/pear/DB.php index 8dce9080e7..b35f51adbe 100644 --- a/pear/DB.php +++ b/pear/DB.php @@ -425,7 +425,7 @@ class DB // Get phptype and dbsyntax // $str => phptype(dbsyntax) - if (preg_match('|^([^(]+)\(([^(]*)\)$|', $str, $arr)) { + if (preg_match('|^(.+?)\((.*?)\)$|', $str, $arr)) { $parsed['phptype'] = $arr[1]; $parsed['dbsyntax'] = (empty($arr[2])) ? $arr[1] : $arr[2]; } else {