diff options
author | Lilli <lilli@janrain.com> | 2010-02-16 11:48:44 -0800 |
---|---|---|
committer | Lilli <lilli@janrain.com> | 2010-02-16 11:48:44 -0800 |
commit | 634d7b470e82e34ca2730c168332232259cf17d1 (patch) | |
tree | 2bcedc9d6cf00380fd1b6a70e02adfa029d43557 /Tests/Auth/OpenID/StoreTest.php | |
parent | f608e5c6312b6232fadac0b6d68874311104fe26 (diff) | |
download | php-openid-634d7b470e82e34ca2730c168332232259cf17d1.zip php-openid-634d7b470e82e34ca2730c168332232259cf17d1.tar.gz php-openid-634d7b470e82e34ca2730c168332232259cf17d1.tar.bz2 |
Added the following patch from the trac.openidenabled.com bug tracker:
http://trac.openidenabled.com/trac/ticket/337
(http://trac.openidenabled.com/trac/attachment/ticket/337/php-openid-php5.3.patch)
Patch makes php-openid library compatible with PHP 5.3, and included changes to many files.
Original Message:
Reported by: http://bfarber.myopenid.com/
Opened 7 months ago
Last modified 2 months ago
PHP OpenID libraries do not work on PHP 5.3
"In my own application the script simply stops working at
function Auth_OpenID_setNoMathSupport() {
if (!defined('Auth_OpenID_NO_MATH_SUPPORT')) {
define('Auth_OpenID_NO_MATH_SUPPORT', true);
}
}
(Namespace issue perhaps?)
I downloaded the latest 2.1.3 libraries available from the site here and set them up on my local server. Using PHP 5.2.9 they work fine (with some notices) however using PHP 5.3 they don't work at all. I just get this one a white screen
Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\openid\php-openid-2.1.3\examples\consumer\common.php on line 72
Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\openid\php-openid-2.1.3\Auth\OpenID\Consumer.php on line 271
Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\openid\php-openid-2.1.3\Auth\OpenID\Consumer.php on line 273"
It should be noted that 34 hunks across about 22 files failed, and I applied most of them manually. 37 files were patched.
Diffstat (limited to 'Tests/Auth/OpenID/StoreTest.php')
-rw-r--r-- | Tests/Auth/OpenID/StoreTest.php | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/Tests/Auth/OpenID/StoreTest.php b/Tests/Auth/OpenID/StoreTest.php index 5e8c8d4..7c50e2f 100644 --- a/Tests/Auth/OpenID/StoreTest.php +++ b/Tests/Auth/OpenID/StoreTest.php @@ -438,9 +438,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { { // If the postgres extension isn't loaded or loadable, succeed // because we can't run the test. - if (!(extension_loaded('pgsql') || - @dl('pgsql.so') || - @dl('php_pgsql.dll')) || + if (!(extension_loaded('pgsql')) || !(@include_once 'DB.php')) { print "(not testing PostGreSQL store)"; $this->pass(); @@ -512,7 +510,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { return; } - $store =& new Auth_OpenID_PostgreSQLStore($db); + $store = new Auth_OpenID_PostgreSQLStore($db); $this->assertFalse($store->tableExists($store->nonces_table_name)); $this->assertFalse($store->tableExists($store->associations_table_name)); @@ -558,9 +556,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { { // If the sqlite extension isn't loaded or loadable, succeed // because we can't run the test. - if (!(extension_loaded('sqlite') || - @dl('sqlite.so') || - @dl('php_sqlite.dll')) || + if (!(extension_loaded('sqlite')) || !(@include_once 'DB.php')) { print "(not testing SQLite store)"; $this->pass(); @@ -585,7 +581,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { $this->pass("SQLite database connection failed: " . $db->getMessage()); } else { - $store =& new Auth_OpenID_SQLiteStore($db); + $store = new Auth_OpenID_SQLiteStore($db); $this->assertTrue($store->createTables(), "Table creation failed"); $this->_testStore($store); $this->_testNonce($store); @@ -603,8 +599,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { { // If the mysql extension isn't loaded or loadable, succeed // because we can't run the test. - if (!(extension_loaded('mysql') || - @dl('mysql.' . PHP_SHLIB_SUFFIX)) || + if (!(extension_loaded('mysql')) || !(@include_once 'DB.php')) { print "(not testing MySQL store)"; $this->pass(); @@ -643,7 +638,7 @@ class Tests_Auth_OpenID_Included_StoreTest extends Tests_Auth_OpenID_Store { $db->query("USE $temp_db_name"); - $store =& new Auth_OpenID_MySQLStore($db); + $store = new Auth_OpenID_MySQLStore($db); $store->createTables(); $this->_testStore($store); $this->_testNonce($store); @@ -720,9 +715,7 @@ class Tests_Auth_OpenID_MemcachedStore_Test extends Tests_Auth_OpenID_Store { { // If the memcache extension isn't loaded or loadable, succeed // because we can't run the test. - if (!(extension_loaded('memcache') || - @dl('memcache.so') || - @dl('php_memcache.dll'))) { + if (!extension_loaded('memcache')) { print "(skipping memcache store tests)"; $this->pass(); return; |