diff options
author | Anna Henningsen <anna@addaleax.net> | 2018-08-31 17:57:03 +0300 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2018-09-03 23:33:42 +0300 |
commit | 71f633a32f1f5617c1c7b60ad936342a579bff74 (patch) | |
tree | bcfc550c80f66a630cc149fbc80f204d0ca6cc62 /src/string_bytes.h | |
parent | 6455bea52ba262cea8d1c706ec8a2eec192ec643 (diff) |
src: allow UTF-16 in generic StringBytes decode call
This allows removing a number of special cases in other
parts of the code, at least one of which was incorrect
in expecting aligned input when that was not guaranteed.
Fixes: https://github.com/nodejs/node/issues/22358
PR-URL: https://github.com/nodejs/node/pull/22622
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Diffstat (limited to 'src/string_bytes.h')
-rw-r--r-- | src/string_bytes.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/string_bytes.h b/src/string_bytes.h index 9e64fa0ee5f..87a296663e1 100644 --- a/src/string_bytes.h +++ b/src/string_bytes.h @@ -90,7 +90,6 @@ class StringBytes { int* chars_written = nullptr); // Take the bytes in the src, and turn it into a Buffer or String. - // Don't call with encoding=UCS2. static v8::MaybeLocal<v8::Value> Encode(v8::Isolate* isolate, const char* buf, size_t buflen, |