<!-- Thank you for reporting a possible bug in Node.js. Please fill in as much of the template below as you can. Version: output of `node -v` Platform: output of `uname -a` (UNIX), or version and 32 or 64-bit (Windows) Subsystem: if known, please specify the affected core module name If possible, please provide code that demonstrates the problem, keeping it as simple and free of external dependencies as you can. --> * **Version**: v10.15.3 * **Platform**: 4.15.0-46-generic #49~16.04.1-Ubuntu x86_64 * **Subsystem**: fs <!-- Please provide more details below this comment. --> Unless the `fs.constants.COPYFILE_EXCL` flag is passed, when `source` and `destination` are the same, Node hangs forever. ``` const fs = require('fs'); fs.writeFileSync('foo', 'Hello World!'); fs.copyFileSync('foo', 'foo'); //Never reach here console.log('Done'); ```