GNOME Bugzilla – Bug 676026
xmlGetLineNo(...) - 65535 row limit
Last modified: 2017-06-08 12:26:05 UTC
Created attachment 213996 [details] ./SAX2.c & ./include/libxml/tree.h patch xmlGetLineNo bug: if a XML file has more than 65535 rows then GetLineNo returns 65535 for each row greater than 65535. The following files have been modified: - include/libxml/tree.h - SAX2.c See the related patch files: - include/libxml/tree.h.patch - SAX2.c.patch
The PHP method DOMNode::getLineNo() doesn't work properly due to this bug. http://www.php.net/manual/en/domnode.getlineno.php
As of libxml2 2.9.0 the option XML_PARSE_BIG_LINES[1] is available, which allows to disable this restriction. It is documented as opt-in (most likely for backward compatibility reasons), so it seems this ticket can be closed. [1] <https://git.gnome.org/browse/libxml2/commit/include/libxml/parser.h?id=968a03a2e54f5bcf53089f5e3c8f790dbe0bf824>