fs: fixes recursive fs.watch crash on Linux when deleting files #54995
Annotations
2 errors
Test:
test/parallel/test-fs-watch-recursive-delete.js#L15
--- stderr ---
/home/runner/work/node/node/test/parallel/test-fs-watch-recursive-delete.js:15
if (fs.readDirSync(tmpdir.resolve('./parent')).length === 0) {
^
TypeError: fs.readDirSync is not a function
at FSWatcher.<anonymous> (/home/runner/work/node/node/test/parallel/test-fs-watch-recursive-delete.js:15:10)
at FSWatcher.<anonymous> (/home/runner/work/node/node/test/common/index.js:473:15)
at FSWatcher.emit (node:events:520:28)
at FSWatcher.<anonymous> (node:internal/fs/recursive_watch:174:14)
at FSWatcher.emit (node:events:520:28)
at FSWatcher._handle.onchange (node:internal/fs/watchers:215:12)
Node.js v22.0.0-pre
Command: out/Release/node --test-reporter=spec --test-reporter-destination=stdout --test-reporter=./tools/github_reporter/index.js --test-reporter-destination=stdout /home/runner/work/node/node/test/parallel/test-fs-watch-recursive-delete.js
|
Test
Process completed with exit code 2.
|
Loading