MCPcopy Index your code
hub / github.com/nodejs/node / closeSync

Method closeSync

lib/internal/vfs/file_system.js:584–591  ·  view source on GitHub ↗

* Closes a file descriptor synchronously. * @param {number} fd The file descriptor

(fd)

Source from the content-addressed store, hash-verified

582 * @param {number} fd The file descriptor
583 */
584 closeSync(fd) {
585 const vfd = getVirtualFd(fd);
586 if (!vfd) {
587 throw createEBADF('close');
588 }
589 vfd.entry.closeSync();
590 closeVirtualFd(fd);
591 }
592
593 /**
594 * Reads from a file descriptor synchronously.

Callers 1

truncateSyncMethod · 0.45

Calls 3

getVirtualFdFunction · 0.85
createEBADFFunction · 0.85
closeVirtualFdFunction · 0.85

Tested by

no test coverage detected