You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Merge pull request #2546 from sparklemotion/flavorjones-canonicalize-incompatible-modes
fix: Document#canonicalize raises exception for incompatible modes
---
**What problem is this PR intended to solve?**
`Document#canonicalize` now raises an exception if `inclusive_namespaces` is non-nil and the mode is inclusive, i.e. XML_C14N_1_0 or XML_C14N_1_1.
`inclusive_namespaces` can only be passed with exclusive modes, and previously this silently failed.
**Have you included adequate test coverage?**
Yes, coverage has been added in this PR.
**Does this change affect the behavior of either the C or the Java implementations?**
Both the C and Java implementations have been updated.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -39,6 +39,7 @@ This version of Nokogiri uses [`jar-dependencies`](https://github.com/mkristian/
39
39
40
40
### Improved
41
41
42
+
*`Document#canonicalize` now raises an exception if `inclusive_namespaces` is non-nil and the mode is inclusive, i.e. XML_C14N_1_0 or XML_C14N_1_1. `inclusive_namespaces` can only be passed with exclusive modes, and previously this silently failed.
42
43
* Compare `Encoding` objects rather than compare their names. This is a slight performance improvement and is future-proof. [[#2454](https://github.com/sparklemotion/nokogiri/issues/2454)] (Thanks, [@casperisfine](https://github.com/casperisfine)!)
43
44
* Avoid compile-time conflict with system-installed `gumbo.h` on OpenBSD. [[#2464](https://github.com/sparklemotion/nokogiri/issues/2464)]
44
45
* Remove calls to `vasprintf` in favor of platform-independent `rb_vsprintf`
0 commit comments