WolframResearch / wstp-rs

Rust bindings to the Wolfram Symbolic Transport Protocol (WSTP)
Apache License 2.0
21 stars 3 forks source link

bugfix: Support null bytes in UTF-8 strings #60

Closed ConnorGray closed 1 year ago

ConnorGray commented 1 year ago

This removes overly-conservative logic that assumed UTF-8 strings passed over WSTP shouldn't contain interior NULL bytes.

The UTF-8 encoding supports NULL bytes, so this logic was failing on well-formed strings.