Re: xmlGetNodePath() returns invalid path for XML_DTD_NODE
Nick Wellnhofer via xml <[email protected]> Mon, 8 Feb 2021 17:23:13 +0100
| Newsgroups | gmane.comp.gnome.lib.xml.general |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format. --------------B1896863DCE78805614A331D Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 28/01/2021 14:51, Christoph M. Becker via xml wrote: > - if ((node == NULL) || (node->type == XML_NAMESPACE_DECL)) > + if ((node == NULL) || (node->type == XML_NAMESPACE_DECL) > + || (node->type == XML_DTD_NODE)) > return (NULL); This should be fixed for other node types as well. Does the attached patch work for you? Nick --------------B1896863DCE78805614A331D Content-Type: text/plain; charset=UTF-8; name="php-bug80680.patch" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="php-bug80680.patch" ZGlmZiAtLWdpdCBhL3RyZWUuYyBiL3RyZWUuYwppbmRleCBkMjM0N2RmZGYuLjYzNmY4MWZl ZCAxMDA2NDQKLS0tIGEvdHJlZS5jCisrKyBiL3RyZWUuYwpAQCAtNDg4MSw3ICs0ODgxLDkg QEAgeG1sR2V0Tm9kZVBhdGgoY29uc3QgeG1sTm9kZSAqbm9kZSkKICAgICAgICAgICAgIH0K ICAgICAgICAgICAgIG5leHQgPSAoKHhtbEF0dHJQdHIpIGN1ciktPnBhcmVudDsKICAgICAg ICAgfSBlbHNlIHsKLSAgICAgICAgICAgIG5leHQgPSBjdXItPnBhcmVudDsKKyAgICAgICAg ICAgIHhtbEZyZWUoYnVmKTsKKyAgICAgICAgICAgIHhtbEZyZWUoYnVmZmVyKTsKKyAgICAg ICAgICAgIHJldHVybiAoTlVMTCk7CiAgICAgICAgIH0KIAogICAgICAgICAvKgo= --------------B1896863DCE78805614A331D Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ xml mailing list, project page http://xmlsoft.org/ [email protected] https://mail.gnome.org/mailman/listinfo/xml --------------B1896863DCE78805614A331D--