From 36fe9d42c194bda130f0d3ac74f2bdd0444e85ef Mon Sep 17 00:00:00 2001 From: David Grudl Date: Wed, 6 Oct 2010 17:23:31 +0200 Subject: [PATCH] PcreException renamed to DibiPcreException --- dibi/dibi.php | 3 +-- dibi/drivers/mysql.php | 2 +- dibi/drivers/mysqli.php | 2 +- dibi/libs/DibiTranslator.php | 4 ++-- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/dibi/dibi.php b/dibi/dibi.php index b1370d7b..91251e50 100644 --- a/dibi/dibi.php +++ b/dibi/dibi.php @@ -44,8 +44,7 @@ if (!defined('NETTE')) { } -/** @package exceptions */ -class PcreException extends Exception { +class DibiPcreException extends Exception { public function __construct($message = '%msg.') { diff --git a/dibi/drivers/mysql.php b/dibi/drivers/mysql.php index 38f3d034..7751aa5e 100644 --- a/dibi/drivers/mysql.php +++ b/dibi/drivers/mysql.php @@ -178,7 +178,7 @@ class DibiMySqlDriver extends DibiObject implements IDibiDriver, IDibiResultDriv { $res = array(); preg_match_all('#(.+?): +(\d+) *#', mysql_info($this->connection), $matches, PREG_SET_ORDER); - if (preg_last_error()) throw new PcreException; + if (preg_last_error()) throw new DibiPcreException; foreach ($matches as $m) { $res[$m[1]] = (int) $m[2]; diff --git a/dibi/drivers/mysqli.php b/dibi/drivers/mysqli.php index b2f407d5..6f88a851 100644 --- a/dibi/drivers/mysqli.php +++ b/dibi/drivers/mysqli.php @@ -175,7 +175,7 @@ class DibiMySqliDriver extends DibiObject implements IDibiDriver, IDibiResultDri { $res = array(); preg_match_all('#(.+?): +(\d+) *#', mysqli_info($this->connection), $matches, PREG_SET_ORDER); - if (preg_last_error()) throw new PcreException; + if (preg_last_error()) throw new DibiPcreException; foreach ($matches as $m) { $res[$m[1]] = (int) $m[2]; diff --git a/dibi/libs/DibiTranslator.php b/dibi/libs/DibiTranslator.php index 0dfac67c..0549239e 100644 --- a/dibi/libs/DibiTranslator.php +++ b/dibi/libs/DibiTranslator.php @@ -121,7 +121,7 @@ final class DibiTranslator extends DibiObject array($this, 'cb'), substr($arg, $toSkip) ); - if (preg_last_error()) throw new PcreException; + if (preg_last_error()) throw new DibiPcreException; } continue; } @@ -379,7 +379,7 @@ final class DibiTranslator extends DibiObject array($this, 'cb'), substr($value, $toSkip) ); - if (preg_last_error()) throw new PcreException; + if (preg_last_error()) throw new DibiPcreException; } return $value;