cvs: php4 /pear/DB odbc.php
| From: | Tomas V.V.Cox | Date: | Sun, 28 Apr 2002 01:51:31 +0000 |
| Subject: | cvs: php4 /pear/DB odbc.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-3588@lists.php.net to get a copy of this message | ||
cox Sat Apr 27 21:51:31 2002 EDT
Modified files:
/php4/pear/DB odbc.php
Log:
Fix odbc_fetch_into() compat for 4.2.0 (reported by Nate Ward)
Index: php4/pear/DB/odbc.php
diff -u php4/pear/DB/odbc.php:1.54 php4/pear/DB/odbc.php:1.55
--- php4/pear/DB/odbc.php:1.54 Thu Feb 28 03:27:11 2002
+++ php4/pear/DB/odbc.php Sat Apr 27 21:51:30 2002
@@ -16,7 +16,7 @@
// | Author: Stig Bakken <ssb@fast.no> |
// +----------------------------------------------------------------------+
//
-// $Id: odbc.php,v 1.54 2002/02/28 08:27:11 sebastian Exp $
+// $Id: odbc.php,v 1.55 2002/04/28 01:51:30 cox Exp $
//
// Database independent query interface definition for PHP's ODBC
// extension.
@@ -220,6 +220,8 @@
$rownum++; // ODBC first row is 1
if (!function_exists('version_compare') || version_compare(phpversion(),
"4.0.5", "lt")) {
$cols = odbc_fetch_into($result, $rownum, &$row);
+ } elseif (version_compare(phpversion(), '4.2.0', 'ge')) {
+ $cols = odbc_fetch_into($result, $row, $rownum);
} else {
$cols = odbc_fetch_into($result, $rownum, $row);
}