File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -41,12 +41,12 @@ for ($i = 4; $i <= 256; $i += 4) {
4141
4242// Incorrect length
4343test_z85_encode ('1234567 ' , null );
44- test_z85_encode (null , null );
44+ test_z85_encode ('' , null );
4545
4646test_z85_decode ('1234567 ' , null );
47- test_z85_decode (null , null );
47+ test_z85_decode ('' , null );
4848
4949echo "OK " ;
5050
5151--EXPECT --
52- OK
52+ OK
Original file line number Diff line number Diff line change @@ -169,10 +169,15 @@ static
169169zend_string * s_create_key (zval * entry )
170170{
171171 if (Z_TYPE_P (entry ) == IS_RESOURCE ) {
172- return strpprintf (0 , "r:%d" , Z_RES_P (entry )-> handle );
172+ /* zend_long since 8.1.0 */
173+ return strpprintf (0 , "r:%ld" , (long )Z_RES_P (entry )-> handle );
173174 }
174175 else {
176+ #if PHP_VERSION_ID >= 80100
177+ zend_string * hash = php_spl_object_hash (Z_OBJ_P (entry ));
178+ #else
175179 zend_string * hash = php_spl_object_hash (entry );
180+ #endif
176181 zend_string * key = strpprintf (0 , "o:%s" , hash -> val );
177182 zend_string_release (hash );
178183 return key ;
You can’t perform that action at this time.
0 commit comments