Skip to content

Commit 2d81db5

Browse files
committed
Remove checks for libxml < 2.6.11
These are below our minimum version requirement.
1 parent 1d0252a commit 2d81db5

File tree

1 file changed

+0
-26
lines changed

1 file changed

+0
-26
lines changed

ext/xmlwriter/php_xmlwriter.c

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,8 @@
2828
#include "php_xmlwriter.h"
2929
#include "ext/standard/php_string.h"
3030

31-
#if LIBXML_VERSION >= 20605
3231
static PHP_FUNCTION(xmlwriter_set_indent);
3332
static PHP_FUNCTION(xmlwriter_set_indent_string);
34-
#endif
3533
static PHP_FUNCTION(xmlwriter_start_attribute);
3634
static PHP_FUNCTION(xmlwriter_end_attribute);
3735
static PHP_FUNCTION(xmlwriter_write_attribute);
@@ -55,25 +53,21 @@ static PHP_FUNCTION(xmlwriter_text);
5553
static PHP_FUNCTION(xmlwriter_write_raw);
5654
static PHP_FUNCTION(xmlwriter_start_document);
5755
static PHP_FUNCTION(xmlwriter_end_document);
58-
#if LIBXML_VERSION >= 20607
5956
static PHP_FUNCTION(xmlwriter_start_comment);
6057
static PHP_FUNCTION(xmlwriter_end_comment);
61-
#endif
6258
static PHP_FUNCTION(xmlwriter_write_comment);
6359
static PHP_FUNCTION(xmlwriter_start_dtd);
6460
static PHP_FUNCTION(xmlwriter_end_dtd);
6561
static PHP_FUNCTION(xmlwriter_write_dtd);
6662
static PHP_FUNCTION(xmlwriter_start_dtd_element);
6763
static PHP_FUNCTION(xmlwriter_end_dtd_element);
6864
static PHP_FUNCTION(xmlwriter_write_dtd_element);
69-
#if LIBXML_VERSION > 20608
7065
static PHP_FUNCTION(xmlwriter_start_dtd_attlist);
7166
static PHP_FUNCTION(xmlwriter_end_dtd_attlist);
7267
static PHP_FUNCTION(xmlwriter_write_dtd_attlist);
7368
static PHP_FUNCTION(xmlwriter_start_dtd_entity);
7469
static PHP_FUNCTION(xmlwriter_end_dtd_entity);
7570
static PHP_FUNCTION(xmlwriter_write_dtd_entity);
76-
#endif
7771
static PHP_FUNCTION(xmlwriter_open_uri);
7872
static PHP_FUNCTION(xmlwriter_open_memory);
7973
static PHP_FUNCTION(xmlwriter_output_memory);
@@ -462,14 +456,10 @@ ZEND_END_ARG_INFO()
462456
static const zend_function_entry xmlwriter_functions[] = {
463457
PHP_FE(xmlwriter_open_uri, arginfo_xmlwriter_open_uri)
464458
PHP_FE(xmlwriter_open_memory, arginfo_xmlwriter_void)
465-
#if LIBXML_VERSION >= 20605
466459
PHP_FE(xmlwriter_set_indent, arginfo_xmlwriter_set_indent)
467460
PHP_FE(xmlwriter_set_indent_string, arginfo_xmlwriter_set_indent_string)
468-
#endif
469-
#if LIBXML_VERSION >= 20607
470461
PHP_FE(xmlwriter_start_comment, arginfo_xmlwriter_resource)
471462
PHP_FE(xmlwriter_end_comment, arginfo_xmlwriter_resource)
472-
#endif
473463
PHP_FE(xmlwriter_start_attribute, arginfo_xmlwriter_start_attribute)
474464
PHP_FE(xmlwriter_end_attribute, arginfo_xmlwriter_resource)
475465
PHP_FE(xmlwriter_write_attribute, arginfo_xmlwriter_write_attribute)
@@ -500,14 +490,12 @@ static const zend_function_entry xmlwriter_functions[] = {
500490
PHP_FE(xmlwriter_start_dtd_element, arginfo_xmlwriter_start_dtd_element)
501491
PHP_FE(xmlwriter_end_dtd_element, arginfo_xmlwriter_resource)
502492
PHP_FE(xmlwriter_write_dtd_element, arginfo_xmlwriter_write_dtd_element)
503-
#if LIBXML_VERSION > 20608
504493
PHP_FE(xmlwriter_start_dtd_attlist, arginfo_xmlwriter_start_dtd_attlist)
505494
PHP_FE(xmlwriter_end_dtd_attlist, arginfo_xmlwriter_resource)
506495
PHP_FE(xmlwriter_write_dtd_attlist, arginfo_xmlwriter_write_dtd_attlist)
507496
PHP_FE(xmlwriter_start_dtd_entity, arginfo_xmlwriter_start_dtd_entity)
508497
PHP_FE(xmlwriter_end_dtd_entity, arginfo_xmlwriter_resource)
509498
PHP_FE(xmlwriter_write_dtd_entity, arginfo_xmlwriter_write_dtd_entity)
510-
#endif
511499
PHP_FE(xmlwriter_output_memory, arginfo_xmlwriter_output_memory)
512500
PHP_FE(xmlwriter_flush, arginfo_xmlwriter_flush)
513501
PHP_FE_END
@@ -518,14 +506,10 @@ static const zend_function_entry xmlwriter_functions[] = {
518506
static const zend_function_entry xmlwriter_class_functions[] = {
519507
PHP_ME_MAPPING(openUri, xmlwriter_open_uri, arginfo_xmlwriter_open_uri, 0)
520508
PHP_ME_MAPPING(openMemory, xmlwriter_open_memory, arginfo_xmlwriter_void, 0)
521-
#if LIBXML_VERSION >= 20605
522509
PHP_ME_MAPPING(setIndent, xmlwriter_set_indent, arginfo_xmlwriter_method_set_indent, 0)
523510
PHP_ME_MAPPING(setIndentString, xmlwriter_set_indent_string, arginfo_xmlwriter_method_set_indent_string, 0)
524-
#endif
525-
#if LIBXML_VERSION >= 20607
526511
PHP_ME_MAPPING(startComment, xmlwriter_start_comment, arginfo_xmlwriter_void, 0)
527512
PHP_ME_MAPPING(endComment, xmlwriter_end_comment, arginfo_xmlwriter_void, 0)
528-
#endif
529513
PHP_ME_MAPPING(startAttribute, xmlwriter_start_attribute, arginfo_xmlwriter_method_start_attribute, 0)
530514
PHP_ME_MAPPING(endAttribute, xmlwriter_end_attribute, arginfo_xmlwriter_void, 0)
531515
PHP_ME_MAPPING(writeAttribute, xmlwriter_write_attribute, arginfo_xmlwriter_method_write_attribute, 0)
@@ -556,14 +540,12 @@ static const zend_function_entry xmlwriter_class_functions[] = {
556540
PHP_ME_MAPPING(startDtdElement, xmlwriter_start_dtd_element,arginfo_xmlwriter_method_start_dtd_element, 0)
557541
PHP_ME_MAPPING(endDtdElement, xmlwriter_end_dtd_element, arginfo_xmlwriter_void, 0)
558542
PHP_ME_MAPPING(writeDtdElement, xmlwriter_write_dtd_element, arginfo_xmlwriter_method_write_dtd_element, 0)
559-
#if LIBXML_VERSION > 20608
560543
PHP_ME_MAPPING(startDtdAttlist, xmlwriter_start_dtd_attlist, arginfo_xmlwriter_method_start_dtd_attlist, 0)
561544
PHP_ME_MAPPING(endDtdAttlist, xmlwriter_end_dtd_attlist, arginfo_xmlwriter_void, 0)
562545
PHP_ME_MAPPING(writeDtdAttlist, xmlwriter_write_dtd_attlist, arginfo_xmlwriter_method_write_dtd_attlist, 0)
563546
PHP_ME_MAPPING(startDtdEntity, xmlwriter_start_dtd_entity, arginfo_xmlwriter_method_start_dtd_entity, 0)
564547
PHP_ME_MAPPING(endDtdEntity, xmlwriter_end_dtd_entity, arginfo_xmlwriter_void, 0)
565548
PHP_ME_MAPPING(writeDtdEntity, xmlwriter_write_dtd_entity, arginfo_xmlwriter_method_write_dtd_entity, 0)
566-
#endif
567549
PHP_ME_MAPPING(outputMemory, xmlwriter_output_memory, arginfo_xmlwriter_method_output_memory, 0)
568550
PHP_ME_MAPPING(flush, xmlwriter_flush, arginfo_xmlwriter_method_flush, 0)
569551
PHP_FE_END
@@ -763,7 +745,6 @@ static void php_xmlwriter_end(INTERNAL_FUNCTION_PARAMETERS, xmlwriter_read_int_t
763745
RETURN_FALSE;
764746
}
765747

766-
#if LIBXML_VERSION >= 20605
767748
/* {{{ proto bool xmlwriter_set_indent(resource xmlwriter, bool indent)
768749
Toggle indentation on/off - returns FALSE on error */
769750
static PHP_FUNCTION(xmlwriter_set_indent)
@@ -811,8 +792,6 @@ static PHP_FUNCTION(xmlwriter_set_indent_string)
811792
}
812793
/* }}} */
813794

814-
#endif
815-
816795
/* {{{ proto bool xmlwriter_start_attribute(resource xmlwriter, string name)
817796
Create start attribute - returns FALSE on error */
818797
static PHP_FUNCTION(xmlwriter_start_attribute)
@@ -1265,7 +1244,6 @@ static PHP_FUNCTION(xmlwriter_text)
12651244
}
12661245
/* }}} */
12671246

1268-
#if LIBXML_VERSION >= 20607
12691247
/* {{{ proto bool xmlwriter_start_comment(resource xmlwriter)
12701248
Create start comment - returns FALSE on error */
12711249
static PHP_FUNCTION(xmlwriter_start_comment)
@@ -1307,8 +1285,6 @@ static PHP_FUNCTION(xmlwriter_end_comment)
13071285
php_xmlwriter_end(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextWriterEndComment);
13081286
}
13091287
/* }}} */
1310-
#endif /* LIBXML_VERSION >= 20607 */
1311-
13121288

13131289
/* {{{ proto bool xmlwriter_write_comment(resource xmlwriter, string content)
13141290
Write full comment tag - returns FALSE on error */
@@ -1512,7 +1488,6 @@ static PHP_FUNCTION(xmlwriter_write_dtd_element)
15121488
}
15131489
/* }}} */
15141490

1515-
#if LIBXML_VERSION > 20608
15161491
/* {{{ proto bool xmlwriter_start_dtd_attlist(resource xmlwriter, string name)
15171492
Create start DTD AttList - returns FALSE on error */
15181493
static PHP_FUNCTION(xmlwriter_start_dtd_attlist)
@@ -1670,7 +1645,6 @@ static PHP_FUNCTION(xmlwriter_write_dtd_entity)
16701645
RETURN_FALSE;
16711646
}
16721647
/* }}} */
1673-
#endif
16741648

16751649
/* {{{ proto resource xmlwriter_open_uri(string source)
16761650
Create new xmlwriter using source uri for output */

0 commit comments

Comments
 (0)