cvs: pear /DB package.xml /DB/DB common.php dbase.php ibase.php msql.php mssql.php mysqli.php oci8.php pgsql.php sqlite.php sybase.php
| From: | Adam Harvey | Date: | Fri, 21 Sep 2007 13:40:42 +0000 |
| Subject: | cvs: pear /DB package.xml /DB/DB common.php dbase.php ibase.php msql.php mssql.php mysqli.php oci8.php pgsql.php sqlite.php sybase.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-48644@lists.php.net to get a copy of this message | ||
aharvey Fri Sep 21 13:40:42 2007 UTC
Modified files:
/pear/DB package.xml
/pear/DB/DB common.php dbase.php ibase.php msql.php mssql.php
mysqli.php oci8.php pgsql.php sqlite.php sybase.php
Log:
Completed request #11581 (Avoid some strict warnings).
http://cvs.php.net/viewvc.cgi/pear/DB/package.xml?r1=1.234&r2=1.235&diff_format=u Index: pear/DB/package.xml diff -u pear/DB/package.xml:1.234 pear/DB/package.xml:1.235 --- pear/DB/package.xml:1.234 Fri Sep 21 13:32:52 2007 +++ pear/DB/package.xml Fri Sep 21 13:40:41 2007 @@ -78,6 +78,9 @@ <notes> This release of DB fixes a number of minor issues reported since the release of DB 1.7.12. +All drivers: +* Replaced instances of '=& new Foo' with '= new Foo' to make DB (slightly) more E_STRICT friendly. Request 11581. + mysql: * Added an explicit call to select the database to fix calls to tableInfo() without a preceding query. Bug 11580. http://cvs.php.net/viewvc.cgi/pear/DB/DB/common.php?r1=1.142&r2=1.143&diff_format=u Index: pear/DB/DB/common.php diff -u pear/DB/DB/common.php:1.142 pear/DB/DB/common.php:1.143 --- pear/DB/DB/common.php:1.142 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/common.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: common.php,v 1.142 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: common.php,v 1.143 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -891,7 +891,7 @@ if (DB::isError($sth)) { return $sth; } - $ret =& $this->execute($sth, array_values($fields_values)); + $ret = $this->execute($sth, array_values($fields_values)); $this->freePrepared($sth); return $ret; @@ -985,7 +985,7 @@ * "'it''s good'", * 'filename.txt' * ); - * $res =& $db->execute($sth, $data); + * $res = $db->execute($sth, $data); * </code> * * @param resource $stmt a DB statement resource returned from prepare() @@ -1095,7 +1095,7 @@ function executeMultiple($stmt, $data) { foreach ($data as $value) { - $res =& $this->execute($stmt, $value); + $res = $this->execute($stmt, $value); if (DB::isError($res)) { return $res; } @@ -1208,7 +1208,7 @@ if (DB::isError($sth)) { return $sth; } - $ret =& $this->execute($sth, $params); + $ret = $this->execute($sth, $params); $this->freePrepared($sth, false); return $ret; } else { @@ -1248,7 +1248,7 @@ if (DB::isError($query)){ return $query; } - $result =& $this->query($query, $params); + $result = $this->query($query, $params); if (is_a($result, 'DB_result')) { $result->setOption('limit_from', $from); $result->setOption('limit_count', $count); @@ -1283,10 +1283,10 @@ if (DB::isError($sth)) { return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1347,10 +1347,10 @@ if (DB::isError($sth)) { return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1398,10 +1398,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1414,7 +1414,7 @@ $ret = array(); } else { if (!array_key_exists($col, $row)) { - $ret =& $this->raiseError(DB_ERROR_NOSUCHFIELD); + $ret = $this->raiseError(DB_ERROR_NOSUCHFIELD); } else { $ret = array($row[$col]); while (is_array($row = $res->fetchRow($fetchmode))) { @@ -1530,10 +1530,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1545,7 +1545,7 @@ $cols = $res->numCols(); if ($cols < 2) { - $tmp =& $this->raiseError(DB_ERROR_TRUNCATED); + $tmp = $this->raiseError(DB_ERROR_TRUNCATED); return $tmp; } @@ -1657,10 +1657,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if ($res === DB_OK || DB::isError($res)) { @@ -1681,7 +1681,7 @@ $res->free(); if (DB::isError($row)) { - $tmp =& $this->raiseError($row); + $tmp = $this->raiseError($row); return $tmp; } return $results; http://cvs.php.net/viewvc.cgi/pear/DB/DB/dbase.php?r1=1.44&r2=1.45&diff_format=u Index: pear/DB/DB/dbase.php diff -u pear/DB/DB/dbase.php:1.44 pear/DB/DB/dbase.php:1.45 --- pear/DB/DB/dbase.php:1.44 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/dbase.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: dbase.php,v 1.44 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: dbase.php,v 1.45 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -188,7 +188,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/ibase.php?r1=1.115&r2=1.116&diff_format=u Index: pear/DB/DB/ibase.php diff -u pear/DB/DB/ibase.php:1.115 pear/DB/DB/ibase.php:1.116 --- pear/DB/DB/ibase.php:1.115 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/ibase.php Fri Sep 21 13:40:41 2007 @@ -23,7 +23,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: ibase.php,v 1.115 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: ibase.php,v 1.116 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -553,9 +553,9 @@ $data = (array)$data; $this->last_parameters = $data; - $types =& $this->prepare_types[(int)$stmt]; + $types = $this->prepare_types[(int)$stmt]; if (count($types) != count($data)) { - $tmp =& $this->raiseError(DB_ERROR_MISMATCH); + $tmp = $this->raiseError(DB_ERROR_MISMATCH); return $tmp; } @@ -574,7 +574,7 @@ } elseif ($types[$i] == DB_PARAM_OPAQUE) { $fp = @fopen($data[$key], 'rb'); if (!$fp) { - $tmp =& $this->raiseError(DB_ERROR_ACCESS_VIOLATION); + $tmp = $this->raiseError(DB_ERROR_ACCESS_VIOLATION); return $tmp; } $data[$key] = fread($fp, filesize($data[$key])); @@ -587,7 +587,7 @@ $res = call_user_func_array('ibase_execute', $data); if (!$res) { - $tmp =& $this->ibaseRaiseError(); + $tmp = $this->ibaseRaiseError(); return $tmp; } /* XXX need this? @@ -707,7 +707,7 @@ $repeat = 0; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT GEN_ID(${sqn}, 1) " + $result = $this->query("SELECT GEN_ID(${sqn}, 1) " . 'FROM RDB$GENERATORS ' . "WHERE RDB\$GENERATOR_NAME='${sqn}'"); $this->popErrorHandling(); @@ -865,7 +865,7 @@ if ($errno === null) { $errno = $this->errorCode($this->errorNative()); } - $tmp =& $this->raiseError($errno, null, null, null, @ibase_errmsg()); + $tmp = $this->raiseError($errno, null, null, null, @ibase_errmsg()); return $tmp; } http://cvs.php.net/viewvc.cgi/pear/DB/DB/msql.php?r1=1.63&r2=1.64&diff_format=u Index: pear/DB/DB/msql.php diff -u pear/DB/DB/msql.php:1.63 pear/DB/DB/msql.php:1.64 --- pear/DB/DB/msql.php:1.63 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/msql.php Fri Sep 21 13:40:41 2007 @@ -23,7 +23,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: msql.php,v 1.63 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: msql.php,v 1.64 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -153,7 +153,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } @@ -443,7 +443,7 @@ $repeat = false; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT _seq FROM ${seqname}"); + $result = $this->query("SELECT _seq FROM ${seqname}"); $this->popErrorHandling(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/mssql.php?r1=1.91&r2=1.92&diff_format=u Index: pear/DB/DB/mssql.php diff -u pear/DB/DB/mssql.php:1.91 pear/DB/DB/mssql.php:1.92 --- pear/DB/DB/mssql.php:1.91 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/mssql.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: mssql.php,v 1.91 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: mssql.php,v 1.92 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -566,14 +566,14 @@ return $this->raiseError($result); } } elseif (!DB::isError($result)) { - $result =& $this->query("SELECT IDENT_CURRENT('$seqname')"); + $result = $this->query("SELECT IDENT_CURRENT('$seqname')"); if (DB::isError($result)) { /* Fallback code for MS SQL Server 7.0, which doesn't have * IDENT_CURRENT. This is *not* safe for concurrent * requests, and really, if you're using it, you're in a * world of hurt. Nevertheless, it's here to ensure BC. See * bug #181 for the gory details.*/ - $result =& $this->query("SELECT @@IDENTITY FROM $seqname"); + $result = $this->query("SELECT @@IDENTITY FROM $seqname"); } $repeat = 0; } else { http://cvs.php.net/viewvc.cgi/pear/DB/DB/mysqli.php?r1=1.81&r2=1.82&diff_format=u Index: pear/DB/DB/mysqli.php diff -u pear/DB/DB/mysqli.php:1.81 pear/DB/DB/mysqli.php:1.82 --- pear/DB/DB/mysqli.php:1.81 Fri Sep 21 13:32:52 2007 +++ pear/DB/DB/mysqli.php Fri Sep 21 13:40:41 2007 @@ -19,7 +19,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: mysqli.php,v 1.81 2007/09/21 13:32:52 aharvey Exp $ + * @version CVS: $Id: mysqli.php,v 1.82 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -271,7 +271,7 @@ * 'ssl' => true, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/oci8.php?r1=1.114&r2=1.115&diff_format=u Index: pear/DB/DB/oci8.php diff -u pear/DB/DB/oci8.php:1.114 pear/DB/DB/oci8.php:1.115 --- pear/DB/DB/oci8.php:1.114 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/oci8.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: oci8.php,v 1.114 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: oci8.php,v 1.115 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -487,7 +487,7 @@ $save_query = $this->last_query; $save_stmt = $this->last_stmt; - $count =& $this->query($countquery); + $count = $this->query($countquery); // Restore the last query and statement. $this->last_query = $save_query; @@ -633,9 +633,9 @@ $this->last_query = $this->_prepared_queries[(int)$stmt]; $this->_data = $data; - $types =& $this->prepare_types[(int)$stmt]; + $types = $this->prepare_types[(int)$stmt]; if (count($types) != count($data)) { - $tmp =& $this->raiseError(DB_ERROR_MISMATCH); + $tmp = $this->raiseError(DB_ERROR_MISMATCH); return $tmp; } @@ -654,7 +654,7 @@ } elseif ($types[$i] == DB_PARAM_OPAQUE) { $fp = @fopen($data[$key], 'rb'); if (!$fp) { - $tmp =& $this->raiseError(DB_ERROR_ACCESS_VIOLATION); + $tmp = $this->raiseError(DB_ERROR_ACCESS_VIOLATION); return $tmp; } $data[$key] = fread($fp, filesize($data[$key])); @@ -818,7 +818,7 @@ if (count($params)) { $result = $this->prepare("SELECT * FROM ($query) " . 'WHERE NULL = NULL'); - $tmp =& $this->execute($result, $params); + $tmp = $this->execute($result, $params); } else { $q_fields = "SELECT * FROM ($query) WHERE NULL = NULL"; @@ -878,7 +878,7 @@ $repeat = 0; do { $this->expectError(DB_ERROR_NOSUCHTABLE); - $result =& $this->query("SELECT ${seqname}.nextval FROM dual"); + $result = $this->query("SELECT ${seqname}.nextval FROM dual"); $this->popExpect(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/pgsql.php?r1=1.137&r2=1.138&diff_format=u Index: pear/DB/DB/pgsql.php diff -u pear/DB/DB/pgsql.php:1.137 pear/DB/DB/pgsql.php:1.138 --- pear/DB/DB/pgsql.php:1.137 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/pgsql.php Fri Sep 21 13:40:41 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: pgsql.php,v 1.137 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: pgsql.php,v 1.138 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -193,7 +193,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } @@ -676,7 +676,7 @@ $repeat = false; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT NEXTVAL('${seqname}')"); + $result = $this->query("SELECT NEXTVAL('${seqname}')"); $this->popErrorHandling(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/sqlite.php?r1=1.115&r2=1.116&diff_format=u Index: pear/DB/DB/sqlite.php diff -u pear/DB/DB/sqlite.php:1.115 pear/DB/DB/sqlite.php:1.116 --- pear/DB/DB/sqlite.php:1.115 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/sqlite.php Fri Sep 21 13:40:42 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 3.0 - * @version CVS: $Id: sqlite.php,v 1.115 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: sqlite.php,v 1.116 2007/09/21 13:40:42 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -182,7 +182,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/sybase.php?r1=1.86&r2=1.87&diff_format=u Index: pear/DB/DB/sybase.php diff -u pear/DB/DB/sybase.php:1.86 pear/DB/DB/sybase.php:1.87 --- pear/DB/DB/sybase.php:1.86 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/sybase.php Fri Sep 21 13:40:42 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: sybase.php,v 1.86 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: sybase.php,v 1.87 2007/09/21 13:40:42 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -479,7 +479,7 @@ return $this->raiseError($result); } } elseif (!DB::isError($result)) { - $result =& $this->query("SELECT @@IDENTITY FROM $seqname"); + $result = $this->query("SELECT @@IDENTITY FROM $seqname"); $repeat = 0; } else { $repeat = false;
http://cvs.php.net/viewvc.cgi/pear/DB/package.xml?r1=1.234&r2=1.235&diff_format=u Index: pear/DB/package.xml diff -u pear/DB/package.xml:1.234 pear/DB/package.xml:1.235 --- pear/DB/package.xml:1.234 Fri Sep 21 13:32:52 2007 +++ pear/DB/package.xml Fri Sep 21 13:40:41 2007 @@ -78,6 +78,9 @@ <notes> This release of DB fixes a number of minor issues reported since the release of DB 1.7.12. +All drivers: +* Replaced instances of '=& new Foo' with '= new Foo' to make DB (slightly) more E_STRICT friendly. Request 11581. + mysql: * Added an explicit call to select the database to fix calls to tableInfo() without a preceding query. Bug 11580. http://cvs.php.net/viewvc.cgi/pear/DB/DB/common.php?r1=1.142&r2=1.143&diff_format=u Index: pear/DB/DB/common.php diff -u pear/DB/DB/common.php:1.142 pear/DB/DB/common.php:1.143 --- pear/DB/DB/common.php:1.142 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/common.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: common.php,v 1.142 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: common.php,v 1.143 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -891,7 +891,7 @@ if (DB::isError($sth)) { return $sth; } - $ret =& $this->execute($sth, array_values($fields_values)); + $ret = $this->execute($sth, array_values($fields_values)); $this->freePrepared($sth); return $ret; @@ -985,7 +985,7 @@ * "'it''s good'", * 'filename.txt' * ); - * $res =& $db->execute($sth, $data); + * $res = $db->execute($sth, $data); * </code> * * @param resource $stmt a DB statement resource returned from prepare() @@ -1095,7 +1095,7 @@ function executeMultiple($stmt, $data) { foreach ($data as $value) { - $res =& $this->execute($stmt, $value); + $res = $this->execute($stmt, $value); if (DB::isError($res)) { return $res; } @@ -1208,7 +1208,7 @@ if (DB::isError($sth)) { return $sth; } - $ret =& $this->execute($sth, $params); + $ret = $this->execute($sth, $params); $this->freePrepared($sth, false); return $ret; } else { @@ -1248,7 +1248,7 @@ if (DB::isError($query)){ return $query; } - $result =& $this->query($query, $params); + $result = $this->query($query, $params); if (is_a($result, 'DB_result')) { $result->setOption('limit_from', $from); $result->setOption('limit_count', $count); @@ -1283,10 +1283,10 @@ if (DB::isError($sth)) { return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1347,10 +1347,10 @@ if (DB::isError($sth)) { return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1398,10 +1398,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1414,7 +1414,7 @@ $ret = array(); } else { if (!array_key_exists($col, $row)) { - $ret =& $this->raiseError(DB_ERROR_NOSUCHFIELD); + $ret = $this->raiseError(DB_ERROR_NOSUCHFIELD); } else { $ret = array($row[$col]); while (is_array($row = $res->fetchRow($fetchmode))) { @@ -1530,10 +1530,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if (DB::isError($res)) { @@ -1545,7 +1545,7 @@ $cols = $res->numCols(); if ($cols < 2) { - $tmp =& $this->raiseError(DB_ERROR_TRUNCATED); + $tmp = $this->raiseError(DB_ERROR_TRUNCATED); return $tmp; } @@ -1657,10 +1657,10 @@ return $sth; } - $res =& $this->execute($sth, $params); + $res = $this->execute($sth, $params); $this->freePrepared($sth); } else { - $res =& $this->query($query); + $res = $this->query($query); } if ($res === DB_OK || DB::isError($res)) { @@ -1681,7 +1681,7 @@ $res->free(); if (DB::isError($row)) { - $tmp =& $this->raiseError($row); + $tmp = $this->raiseError($row); return $tmp; } return $results; http://cvs.php.net/viewvc.cgi/pear/DB/DB/dbase.php?r1=1.44&r2=1.45&diff_format=u Index: pear/DB/DB/dbase.php diff -u pear/DB/DB/dbase.php:1.44 pear/DB/DB/dbase.php:1.45 --- pear/DB/DB/dbase.php:1.44 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/dbase.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: dbase.php,v 1.44 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: dbase.php,v 1.45 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -188,7 +188,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/ibase.php?r1=1.115&r2=1.116&diff_format=u Index: pear/DB/DB/ibase.php diff -u pear/DB/DB/ibase.php:1.115 pear/DB/DB/ibase.php:1.116 --- pear/DB/DB/ibase.php:1.115 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/ibase.php Fri Sep 21 13:40:41 2007 @@ -23,7 +23,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: ibase.php,v 1.115 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: ibase.php,v 1.116 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -553,9 +553,9 @@ $data = (array)$data; $this->last_parameters = $data; - $types =& $this->prepare_types[(int)$stmt]; + $types = $this->prepare_types[(int)$stmt]; if (count($types) != count($data)) { - $tmp =& $this->raiseError(DB_ERROR_MISMATCH); + $tmp = $this->raiseError(DB_ERROR_MISMATCH); return $tmp; } @@ -574,7 +574,7 @@ } elseif ($types[$i] == DB_PARAM_OPAQUE) { $fp = @fopen($data[$key], 'rb'); if (!$fp) { - $tmp =& $this->raiseError(DB_ERROR_ACCESS_VIOLATION); + $tmp = $this->raiseError(DB_ERROR_ACCESS_VIOLATION); return $tmp; } $data[$key] = fread($fp, filesize($data[$key])); @@ -587,7 +587,7 @@ $res = call_user_func_array('ibase_execute', $data); if (!$res) { - $tmp =& $this->ibaseRaiseError(); + $tmp = $this->ibaseRaiseError(); return $tmp; } /* XXX need this? @@ -707,7 +707,7 @@ $repeat = 0; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT GEN_ID(${sqn}, 1) " + $result = $this->query("SELECT GEN_ID(${sqn}, 1) " . 'FROM RDB$GENERATORS ' . "WHERE RDB\$GENERATOR_NAME='${sqn}'"); $this->popErrorHandling(); @@ -865,7 +865,7 @@ if ($errno === null) { $errno = $this->errorCode($this->errorNative()); } - $tmp =& $this->raiseError($errno, null, null, null, @ibase_errmsg()); + $tmp = $this->raiseError($errno, null, null, null, @ibase_errmsg()); return $tmp; } http://cvs.php.net/viewvc.cgi/pear/DB/DB/msql.php?r1=1.63&r2=1.64&diff_format=u Index: pear/DB/DB/msql.php diff -u pear/DB/DB/msql.php:1.63 pear/DB/DB/msql.php:1.64 --- pear/DB/DB/msql.php:1.63 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/msql.php Fri Sep 21 13:40:41 2007 @@ -23,7 +23,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: msql.php,v 1.63 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: msql.php,v 1.64 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -153,7 +153,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } @@ -443,7 +443,7 @@ $repeat = false; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT _seq FROM ${seqname}"); + $result = $this->query("SELECT _seq FROM ${seqname}"); $this->popErrorHandling(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/mssql.php?r1=1.91&r2=1.92&diff_format=u Index: pear/DB/DB/mssql.php diff -u pear/DB/DB/mssql.php:1.91 pear/DB/DB/mssql.php:1.92 --- pear/DB/DB/mssql.php:1.91 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/mssql.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: mssql.php,v 1.91 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: mssql.php,v 1.92 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -566,14 +566,14 @@ return $this->raiseError($result); } } elseif (!DB::isError($result)) { - $result =& $this->query("SELECT IDENT_CURRENT('$seqname')"); + $result = $this->query("SELECT IDENT_CURRENT('$seqname')"); if (DB::isError($result)) { /* Fallback code for MS SQL Server 7.0, which doesn't have * IDENT_CURRENT. This is *not* safe for concurrent * requests, and really, if you're using it, you're in a * world of hurt. Nevertheless, it's here to ensure BC. See * bug #181 for the gory details.*/ - $result =& $this->query("SELECT @@IDENTITY FROM $seqname"); + $result = $this->query("SELECT @@IDENTITY FROM $seqname"); } $repeat = 0; } else { http://cvs.php.net/viewvc.cgi/pear/DB/DB/mysqli.php?r1=1.81&r2=1.82&diff_format=u Index: pear/DB/DB/mysqli.php diff -u pear/DB/DB/mysqli.php:1.81 pear/DB/DB/mysqli.php:1.82 --- pear/DB/DB/mysqli.php:1.81 Fri Sep 21 13:32:52 2007 +++ pear/DB/DB/mysqli.php Fri Sep 21 13:40:41 2007 @@ -19,7 +19,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: mysqli.php,v 1.81 2007/09/21 13:32:52 aharvey Exp $ + * @version CVS: $Id: mysqli.php,v 1.82 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -271,7 +271,7 @@ * 'ssl' => true, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/oci8.php?r1=1.114&r2=1.115&diff_format=u Index: pear/DB/DB/oci8.php diff -u pear/DB/DB/oci8.php:1.114 pear/DB/DB/oci8.php:1.115 --- pear/DB/DB/oci8.php:1.114 Sun Aug 12 05:27:25 2007 +++ pear/DB/DB/oci8.php Fri Sep 21 13:40:41 2007 @@ -20,7 +20,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: oci8.php,v 1.114 2007/08/12 05:27:25 aharvey Exp $ + * @version CVS: $Id: oci8.php,v 1.115 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -487,7 +487,7 @@ $save_query = $this->last_query; $save_stmt = $this->last_stmt; - $count =& $this->query($countquery); + $count = $this->query($countquery); // Restore the last query and statement. $this->last_query = $save_query; @@ -633,9 +633,9 @@ $this->last_query = $this->_prepared_queries[(int)$stmt]; $this->_data = $data; - $types =& $this->prepare_types[(int)$stmt]; + $types = $this->prepare_types[(int)$stmt]; if (count($types) != count($data)) { - $tmp =& $this->raiseError(DB_ERROR_MISMATCH); + $tmp = $this->raiseError(DB_ERROR_MISMATCH); return $tmp; } @@ -654,7 +654,7 @@ } elseif ($types[$i] == DB_PARAM_OPAQUE) { $fp = @fopen($data[$key], 'rb'); if (!$fp) { - $tmp =& $this->raiseError(DB_ERROR_ACCESS_VIOLATION); + $tmp = $this->raiseError(DB_ERROR_ACCESS_VIOLATION); return $tmp; } $data[$key] = fread($fp, filesize($data[$key])); @@ -818,7 +818,7 @@ if (count($params)) { $result = $this->prepare("SELECT * FROM ($query) " . 'WHERE NULL = NULL'); - $tmp =& $this->execute($result, $params); + $tmp = $this->execute($result, $params); } else { $q_fields = "SELECT * FROM ($query) WHERE NULL = NULL"; @@ -878,7 +878,7 @@ $repeat = 0; do { $this->expectError(DB_ERROR_NOSUCHTABLE); - $result =& $this->query("SELECT ${seqname}.nextval FROM dual"); + $result = $this->query("SELECT ${seqname}.nextval FROM dual"); $this->popExpect(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/pgsql.php?r1=1.137&r2=1.138&diff_format=u Index: pear/DB/DB/pgsql.php diff -u pear/DB/DB/pgsql.php:1.137 pear/DB/DB/pgsql.php:1.138 --- pear/DB/DB/pgsql.php:1.137 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/pgsql.php Fri Sep 21 13:40:41 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: pgsql.php,v 1.137 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: pgsql.php,v 1.138 2007/09/21 13:40:41 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -193,7 +193,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } @@ -676,7 +676,7 @@ $repeat = false; do { $this->pushErrorHandling(PEAR_ERROR_RETURN); - $result =& $this->query("SELECT NEXTVAL('${seqname}')"); + $result = $this->query("SELECT NEXTVAL('${seqname}')"); $this->popErrorHandling(); if ($ondemand && DB::isError($result) && $result->getCode() == DB_ERROR_NOSUCHTABLE) { http://cvs.php.net/viewvc.cgi/pear/DB/DB/sqlite.php?r1=1.115&r2=1.116&diff_format=u Index: pear/DB/DB/sqlite.php diff -u pear/DB/DB/sqlite.php:1.115 pear/DB/DB/sqlite.php:1.116 --- pear/DB/DB/sqlite.php:1.115 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/sqlite.php Fri Sep 21 13:40:42 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 3.0 - * @version CVS: $Id: sqlite.php,v 1.115 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: sqlite.php,v 1.116 2007/09/21 13:40:42 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -182,7 +182,7 @@ * 'portability' => DB_PORTABILITY_ALL, * ); * - * $db =& DB::connect($dsn, $options); + * $db = DB::connect($dsn, $options); * if (PEAR::isError($db)) { * die($db->getMessage()); * } http://cvs.php.net/viewvc.cgi/pear/DB/DB/sybase.php?r1=1.86&r2=1.87&diff_format=u Index: pear/DB/DB/sybase.php diff -u pear/DB/DB/sybase.php:1.86 pear/DB/DB/sybase.php:1.87 --- pear/DB/DB/sybase.php:1.86 Fri Jul 6 05:19:21 2007 +++ pear/DB/DB/sybase.php Fri Sep 21 13:40:42 2007 @@ -21,7 +21,7 @@ * @author Daniel Convissor <danielc@php.net> * @copyright 1997-2007 The PHP Group * @license http://www.php.net/license/3_0.txt PHP License 3.0 - * @version CVS: $Id: sybase.php,v 1.86 2007/07/06 05:19:21 aharvey Exp $ + * @version CVS: $Id: sybase.php,v 1.87 2007/09/21 13:40:42 aharvey Exp $ * @link http://pear.php.net/package/DB */ @@ -479,7 +479,7 @@ return $this->raiseError($result); } } elseif (!DB::isError($result)) { - $result =& $this->query("SELECT @@IDENTITY FROM $seqname"); + $result = $this->query("SELECT @@IDENTITY FROM $seqname"); $repeat = 0; } else { $repeat = false;