Skip to content

crypto: fix randomInt range check

The current implementation allows crypto.randomInt(0) and returns NaN.

Refs: https://github.com/nodejs/node/pull/34600

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines

Merge request reports

Loading