Unverified Commit 345e7937 authored by Denys Otrishko's avatar Denys Otrishko Committed by Shelley Vohr
Browse files

fs: fix realpath inode link caching

The `fs.realpath` / `fs.realpathSync` cache already seen symbolic links
using the inode number which may be longer that max supported
JS number (2**53) and will therefore be incorrectly handled by possibly
entering infinite loop of calling stat on the same node.

This PR changes those functions (where appropriate) to use
bigint for inode numbers.

Fixes: https://github.com/nodejs/node/issues/33936

PR-URL: https://github.com/nodejs/node/pull/33945


Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarBen Noordhuis <info@bnoordhuis.nl>
Reviewed-By: default avatarAnna Henningsen <anna@addaleax.net>
parent 32bbdc45
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment