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
It would be nice if we could asynchroneously parse an XML document from a string literal. Document.fromXmlAsync isn't completely up to that task since it passes NULL as the encoding argument to its xmlReadMemory call, which presumably triggers auto-detection of file encoding. So it could be that some application has a string which originally got read from a non-UTF-8 file and therefore starts with a non-UTF-8 encoding in the xml header. But it's a string, and turning that into a Buffer will use UTF-8. Performing auto-detection on that buffer will likely lead to incorrect input.
It would be nice if we could asynchroneously parse an XML document from a string literal.
Document.fromXmlAsync
isn't completely up to that task since it passesNULL
as theencoding
argument to itsxmlReadMemory
call, which presumably triggers auto-detection of file encoding. So it could be that some application has a string which originally got read from a non-UTF-8 file and therefore starts with a non-UTF-8 encoding in the xml header. But it's a string, and turning that into a Buffer will use UTF-8. Performing auto-detection on that buffer will likely lead to incorrect input.This would be needed for albanm/node-libxslt#35.
The text was updated successfully, but these errors were encountered: