mirror of https://github.com/lukechilds/node.git
Browse Source
Use `StringBytes::Size` to determine the needle string length instead of assuming latin-1 or UTF-8. Previously, `Buffer.indexOf` could fail with an assertion failure when the needle's byte length, but not its character count, exceeded the haystack's byte length. PR-URL: https://github.com/nodejs/node/pull/6511 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Trevor Norris <trev.norris@gmail.com>process-exit-stdio-flushing
Anna Henningsen
9 years ago
2 changed files with 8 additions and 2 deletions
Loading…
Reference in new issue