Skip to content

Commit

Permalink
Update ncp.js
Browse files Browse the repository at this point in the history
allow copying of character or block devices (NB: copies contents, not the inode)
  • Loading branch information
raybellis committed Dec 17, 2015
1 parent 631ed20 commit 141422e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/copy/ncp.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ function ncp (source, dest, options, callback) {

if (stats.isDirectory()) {
return onDir(item)
} else if (stats.isFile()) {
} else if (stats.isFile() || stats.isCharacterDevice() || stats.isBlockDevice()) {
return onFile(item)
} else if (stats.isSymbolicLink()) {
// Symlinks don't really need to know about the mode.
Expand Down

0 comments on commit 141422e

Please sign in to comment.