From 4fc6efd82f07d5668070d64b126c7bb324291153 Mon Sep 17 00:00:00 2001 From: zYne Date: Wed, 29 Aug 2007 21:57:46 +0000 Subject: [PATCH] fixes #440 --- lib/Doctrine/Connection.php | 3 ++- lib/Doctrine/Manager.php | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/Doctrine/Connection.php b/lib/Doctrine/Connection.php index 3dc0705a7..f7b4ee16c 100644 --- a/lib/Doctrine/Connection.php +++ b/lib/Doctrine/Connection.php @@ -1016,7 +1016,7 @@ abstract class Doctrine_Connection extends Doctrine_Configurable implements Coun $this->clear(); - $this->dbh = null; + unset($this->dbh); $this->isConnected = false; $this->getAttribute(Doctrine::ATTR_LISTENER)->postClose($event); @@ -1122,6 +1122,7 @@ abstract class Doctrine_Connection extends Doctrine_Configurable implements Coun { $this->transaction->rollback($savepoint); } + /** * returns a string representation of this object * @return string diff --git a/lib/Doctrine/Manager.php b/lib/Doctrine/Manager.php index 176937780..616d50439 100644 --- a/lib/Doctrine/Manager.php +++ b/lib/Doctrine/Manager.php @@ -291,6 +291,9 @@ class Doctrine_Manager extends Doctrine_Configurable implements Countable, Itera if (isset($parts['host']) && $parts['host'] == ':memory') { $parts['database'] = ':memory:'; $parts['dsn'] = 'sqlite::memory:'; + } else { + $parts['database'] = $parts['path']; + $parts['dsn'] = $parts['scheme'] . ':' . $parts['path']; } break;