Commit c82e580a authored by Bruno Jouhier's avatar Bruno Jouhier Committed by cjihrig
Browse files

fs: properly handle fd passed to truncate()

Currently, fs.truncate() silently fails when a file descriptor
is passed as the first argument. This commit changes this
behavior to properly call fs.ftruncate().

PR-URL: https://github.com/joyent/node/pull/9161


Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
Reviewed-By: default avatarTimothy J Fontaine <tjfontaine@gmail.com>
Reviewed-By: default avatarBen Noordhuis <info@bnoordhuis.nl>

Conflicts:
	lib/fs.js
parent 4fcbb8aa
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