Diff for /embedaddon/php/ext/soap/php_packet_soap.c between versions 1.1.1.1 and 1.1.1.2

version 1.1.1.1, 2012/02/21 23:48:01 version 1.1.1.2, 2012/05/29 12:34:42
Line 191  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 191  int parse_packet_soap(zval *this_ptr, char *buffer, in
   
                         tmp = get_node(fault->children, "faultstring");                          tmp = get_node(fault->children, "faultstring");
                         if (tmp != NULL && tmp->children != NULL) {                          if (tmp != NULL && tmp->children != NULL) {
                                zval *zv = master_to_zval(get_conversion(IS_STRING), tmp);                                zval *zv = master_to_zval(get_conversion(IS_STRING), tmp TSRMLS_CC);
                                 faultstring = Z_STRVAL_P(zv);                                  faultstring = Z_STRVAL_P(zv);
                                 FREE_ZVAL(zv);                                  FREE_ZVAL(zv);
                         }                          }
   
                         tmp = get_node(fault->children, "faultactor");                          tmp = get_node(fault->children, "faultactor");
                         if (tmp != NULL && tmp->children != NULL) {                          if (tmp != NULL && tmp->children != NULL) {
                                zval *zv = master_to_zval(get_conversion(IS_STRING), tmp);                                zval *zv = master_to_zval(get_conversion(IS_STRING), tmp TSRMLS_CC);
                                 faultactor = Z_STRVAL_P(zv);                                  faultactor = Z_STRVAL_P(zv);
                                 FREE_ZVAL(zv);                                  FREE_ZVAL(zv);
                         }                          }
   
                         tmp = get_node(fault->children, "detail");                          tmp = get_node(fault->children, "detail");
                         if (tmp != NULL) {                          if (tmp != NULL) {
                                details = master_to_zval(NULL, tmp);                                details = master_to_zval(NULL, tmp TSRMLS_CC);
                         }                          }
                 } else {                  } else {
                         tmp = get_node(fault->children, "Code");                          tmp = get_node(fault->children, "Code");
Line 221  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 221  int parse_packet_soap(zval *this_ptr, char *buffer, in
                                 /* TODO: lang attribute */                                  /* TODO: lang attribute */
                                 tmp = get_node(tmp->children,"Text");                                  tmp = get_node(tmp->children,"Text");
                                 if (tmp != NULL && tmp->children != NULL) {                                  if (tmp != NULL && tmp->children != NULL) {
                                        zval *zv = master_to_zval(get_conversion(IS_STRING), tmp);                                        zval *zv = master_to_zval(get_conversion(IS_STRING), tmp TSRMLS_CC);
                                         faultstring = Z_STRVAL_P(zv);                                          faultstring = Z_STRVAL_P(zv);
                                         FREE_ZVAL(zv);                                          FREE_ZVAL(zv);
                                 }                                  }
Line 229  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 229  int parse_packet_soap(zval *this_ptr, char *buffer, in
   
                         tmp = get_node(fault->children,"Detail");                          tmp = get_node(fault->children,"Detail");
                         if (tmp != NULL) {                          if (tmp != NULL) {
                                details = master_to_zval(NULL, tmp);                                details = master_to_zval(NULL, tmp TSRMLS_CC);
                         }                          }
                 }                  }
                 add_soap_fault(this_ptr, faultcode, faultstring, faultactor, details TSRMLS_CC);                  add_soap_fault(this_ptr, faultcode, faultstring, faultactor, details TSRMLS_CC);
Line 239  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 239  int parse_packet_soap(zval *this_ptr, char *buffer, in
                 if (faultactor) {                  if (faultactor) {
                         efree(faultactor);                          efree(faultactor);
                 }                  }
 #ifdef ZEND_ENGINE_2  
                 if (details) {                  if (details) {
                         Z_DELREF_P(details);                          Z_DELREF_P(details);
                 }                  }
 #endif  
                 xmlFreeDoc(response);                  xmlFreeDoc(response);
                 return FALSE;                  return FALSE;
         }          }
Line 327  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 325  int parse_packet_soap(zval *this_ptr, char *buffer, in
                                         } else {                                          } else {
                                                 /* Decoding value of parameter */                                                  /* Decoding value of parameter */
                                                 if (param != NULL) {                                                  if (param != NULL) {
                                                        tmp = master_to_zval(param->encode, val);                                                        tmp = master_to_zval(param->encode, val TSRMLS_CC);
                                                 } else {                                                  } else {
                                                        tmp = master_to_zval(NULL, val);                                                        tmp = master_to_zval(NULL, val TSRMLS_CC);
                                                 }                                                  }
                                         }                                          }
                                         add_assoc_zval(return_value, param->paramName, tmp);                                          add_assoc_zval(return_value, param->paramName, tmp);
Line 352  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 350  int parse_packet_soap(zval *this_ptr, char *buffer, in
                                                 zval *tmp;                                                  zval *tmp;
                                                 zval **arr;                                                  zval **arr;
   
                                                tmp = master_to_zval(NULL, val);                                                tmp = master_to_zval(NULL, val TSRMLS_CC);
                                                 if (val->name) {                                                  if (val->name) {
                                                         if (zend_hash_find(Z_ARRVAL_P(return_value), (char*)val->name, strlen((char*)val->name)+1, (void**)&arr) == SUCCESS) {                                                          if (zend_hash_find(Z_ARRVAL_P(return_value), (char*)val->name, strlen((char*)val->name)+1, (void**)&arr) == SUCCESS) {
                                                                 add_next_index_zval(*arr, tmp);                                                                  add_next_index_zval(*arr, tmp);
Line 416  int parse_packet_soap(zval *this_ptr, char *buffer, in Line 414  int parse_packet_soap(zval *this_ptr, char *buffer, in
                                         }                                          }
                                         smart_str_free(&key);                                          smart_str_free(&key);
                                 }                                  }
                                val = master_to_zval(enc, trav);                                val = master_to_zval(enc, trav TSRMLS_CC);
                                 add_assoc_zval(soap_headers, (char*)trav->name, val);                                  add_assoc_zval(soap_headers, (char*)trav->name, val);
                         }                          }
                         trav = trav->next;                          trav = trav->next;

Removed from v.1.1.1.1  
changed lines
  Added in v.1.1.1.2


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>