summaryrefslogtreecommitdiff
path: root/ext/xmlreader/php_xmlreader.c
diff options
context:
space:
mode:
authorStanley Sufficool <ssufficool@php.net>2013-10-05 17:57:23 -0700
committerStanley Sufficool <ssufficool@php.net>2013-10-05 17:57:23 -0700
commit3e023c3ddf9e80046803a989f4951ee16d3b8f9b (patch)
tree602f3b798d09f49f069fd9a046d502931f56c158 /ext/xmlreader/php_xmlreader.c
parentb144c263191f857391d3cc009951c95d25a2cdb3 (diff)
parent3261eb348f5aea14f74010d883cfc68978fd8ed9 (diff)
downloadphp-git-3e023c3ddf9e80046803a989f4951ee16d3b8f9b.tar.gz
Merge branch 'master' of https://git.php.net/push/php-src
* 'master' of https://git.php.net/push/php-src: (705 commits) Allow the ldap extension to be compiled with Oracle's LDAP implementation, if desired. Note the implementations differ so you will see different ldap behavior. Fix bug #65667: ftp_nb_continue produces segfault fix bug #64146 (serialize incorrectly saving objects when they are cloned) such a weird hack probably helps in finding regressions in the future Fix bug #65821: By-ref foreach on property access of string offset segfaults Fixed bug #64230 (XMLReader does not suppress errors) add NEWS and UPGRADING about gost-crypto fix bug #55285 XMLReader::getAttribute/No/Ns methods inconsistency typo: really fix bug #51936 Crash with clone xmlreader fix bug #59613 (Crash with clone XMLReader) Fix Bug #60633 build warning in bcmath fix bug #65808 the socket_connect() won't work with IPv6 address 5.4.22-dev now Revert "Make 'make distclean' remove the downloaded pear PHAR" fix bug #62396 'make test' crashes starting with 5.3.14 (missing gzencode()) Fixed bug #61548 Reverted patch (it was used for internal testing and was committed by accident) OCI8 2.0: Added a new oci_set_db_operation() user space function for the "DB Operation" tracing feature of Oracle DB 12c. Make 'make distclean' remove the downloaded pear PHAR fix test ...
Diffstat (limited to 'ext/xmlreader/php_xmlreader.c')
-rw-r--r--ext/xmlreader/php_xmlreader.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c
index 3c5bc32f28..76cd56f144 100644
--- a/ext/xmlreader/php_xmlreader.c
+++ b/ext/xmlreader/php_xmlreader.c
@@ -588,9 +588,6 @@ PHP_METHOD(xmlreader, getAttributeNo)
if (retchar) {
RETVAL_STRING(retchar, 1);
xmlFree(retchar);
- return;
- } else {
- RETURN_EMPTY_STRING();
}
}
/* }}} */
@@ -622,9 +619,6 @@ PHP_METHOD(xmlreader, getAttributeNs)
if (retchar) {
RETVAL_STRING(retchar, 1);
xmlFree(retchar);
- return;
- } else {
- RETURN_EMPTY_STRING();
}
}
/* }}} */
@@ -708,7 +702,7 @@ PHP_METHOD(xmlreader, moveToAttribute)
/* }}} */
/* {{{ proto boolean XMLReader::moveToAttributeNo(int index)
-Positions reader at attribute at spcecified index.
+Positions reader at attribute at specified index.
Returns TRUE on success and FALSE on failure */
PHP_METHOD(xmlreader, moveToAttributeNo)
{
@@ -805,7 +799,6 @@ PHP_METHOD(xmlreader, read)
if (intern != NULL && intern->ptr != NULL) {
retval = xmlTextReaderRead(intern->ptr);
if (retval == -1) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "An Error Occured while reading");
RETURN_FALSE;
} else {
RETURN_BOOL(retval);
@@ -847,7 +840,6 @@ PHP_METHOD(xmlreader, next)
retval = xmlTextReaderNext(intern->ptr);
}
if (retval == -1) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "An Error Occured while reading");
RETURN_FALSE;
} else {
RETURN_BOOL(retval);
@@ -1155,7 +1147,7 @@ PHP_METHOD(xmlreader, expand)
node = xmlTextReaderExpand(intern->ptr);
if (node == NULL) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "An Error Occured while expanding ");
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "An Error Occurred while expanding ");
RETURN_FALSE;
} else {
nodec = xmlDocCopyNode(node, docp, 1);
@@ -1320,6 +1312,7 @@ PHP_MINIT_FUNCTION(xmlreader)
xmlreader_object_handlers.read_property = xmlreader_read_property;
xmlreader_object_handlers.write_property = xmlreader_write_property;
xmlreader_object_handlers.get_property_ptr_ptr = xmlreader_get_property_ptr_ptr;
+ xmlreader_object_handlers.clone_obj = NULL;
INIT_CLASS_ENTRY(ce, "XMLReader", xmlreader_functions);
ce.create_object = xmlreader_objects_new;