DB_DataObject::createTables fatal error

From: Date: Thu, 06 Jan 2005 02:48:50 +0000
Subject: DB_DataObject::createTables fatal error
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-16717@lists.php.net to get a copy of this message
On a windows machine + php 4.3.10 + DB_DataObject 1.7.2 (also tested with 1.7.1) + define('DB_DATAOBJECT_NO_OVERLOAD',true); createTables.php always give : "Fatal error : call to a member function on a non object in c:\path\...\Generator.php on line 132" $t is indeed a valid generator object before calling _createTableList() and NULL after... I don't know why. I Suspect some php 4.3.10 weird behaviour. Making instance by reference ($t =& new $class; instead of $t = new $class;) on line 121 solves the problem.
     $class = get_class($this);
           $t =& new $class;
           $t->_database_dsn = $database;
           $t->_database = $databasename;
           $t->_createTableList();
Hope this can help. Regards, Didier

« previous php.pear.general (#16717) next »