buffer: add type check in bidirectionalIndexOf
Add a type check in bidirectionalIndexOf to avoid using something else as Buffer. This may happen if e.g. lastIndexOf is called with invalid this. PR-URL: https://github.com/nodejs/node/pull/32770 Fixes: https://github.com/nodejs/node/issues/32753 Fixes: https://github.com/nodejs/node/issues/32747 Reviewed-By:Anna Henningsen <anna@addaleax.net> Reviewed-By:
Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By:
Yongsheng Zhang <zyszys98@gmail.com>
parent
1211b9a7
Please register or sign in to comment