Skip to content

Conversation

blar
Copy link
Contributor

@blar blar commented Jul 23, 2017

xmlrpc_encode and xmlrpc_encode_request works different if the properties $xmlrpc_type and $scalar are defined before assigning values to an object.

If the properties $xmlrpc_type and $scalar are defined, xmlrpc_encode* don't use the values for serialization.

https://bugs.php.net/bug.php?id=74975

@@ -1355,6 +1355,9 @@ XMLRPC_VALUE_TYPE get_zval_xmlrpc_type(zval* value, zval* newvalue) /* {{{ */
type = xmlrpc_vector;

if ((attr = zend_hash_str_find(Z_OBJPROP_P(value), OBJECT_TYPE_ATTR, sizeof(OBJECT_TYPE_ATTR) - 1)) != NULL) {
if(Z_TYPE_P(attr) == IS_INDIRECT) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can use zend_hash_str_find_ind for this

@krakjoe krakjoe added the Bug label Jul 24, 2017
@nikic
Copy link
Member

nikic commented Aug 2, 2017

Merged as c2b8066 into 7.0+. Thanks!

@nikic nikic closed this Aug 2, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants