-
Notifications
You must be signed in to change notification settings - Fork 29.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fs.ftruncate cannot truncate to lengths > 2GB #20844
Labels
confirmed-bug
Issues with confirmed bugs.
fs
Issues and PRs related to the fs subsystem / file system.
Comments
/cc @BridgeAR |
BridgeAR
added
confirmed-bug
Issues with confirmed bugs.
fs
Issues and PRs related to the fs subsystem / file system.
labels
May 20, 2018
3 tasks
cjihrig
added a commit
to cjihrig/node
that referenced
this issue
May 26, 2018
This allows validation of integers that are not int32 or uint32. PR-URL: nodejs#20851 Fixes: nodejs#20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
cjihrig
added a commit
to cjihrig/node
that referenced
this issue
May 26, 2018
This commit adds validation to the length parameter of fs.truncate(). Prior to this commit, passing a non-number would trigger a CHECK() in the binding layer. PR-URL: nodejs#20851 Fixes: nodejs#20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
cjihrig
added a commit
to cjihrig/node
that referenced
this issue
May 26, 2018
The length used by ftruncate() is 64 bits in the binding layer. This commit removes the 32 bit restriction in the JS layer. PR-URL: nodejs#20851 Fixes: nodejs#20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Thank you! |
targos
pushed a commit
that referenced
this issue
Jun 6, 2018
This allows validation of integers that are not int32 or uint32. PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 6, 2018
This commit adds validation to the length parameter of fs.truncate(). Prior to this commit, passing a non-number would trigger a CHECK() in the binding layer. Backport-PR-URL: #21171 PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 6, 2018
The length used by ftruncate() is 64 bits in the binding layer. This commit removes the 32 bit restriction in the JS layer. Backport-PR-URL: #21171 PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 7, 2018
The length used by ftruncate() is 64 bits in the binding layer. This commit removes the 32 bit restriction in the JS layer. Backport-PR-URL: #21171 PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 13, 2018
This allows validation of integers that are not int32 or uint32. PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 13, 2018
This commit adds validation to the length parameter of fs.truncate(). Prior to this commit, passing a non-number would trigger a CHECK() in the binding layer. Backport-PR-URL: #21171 PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
targos
pushed a commit
that referenced
this issue
Jun 13, 2018
The length used by ftruncate() is 64 bits in the binding layer. This commit removes the 32 bit restriction in the JS layer. Backport-PR-URL: #21171 PR-URL: #20851 Fixes: #20844 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Backport-PR-URL: #21171 Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
confirmed-bug
Issues with confirmed bugs.
fs
Issues and PRs related to the fs subsystem / file system.
fs.ftruncate
, in Node 10, attempts to do some length checking, which I don't recall being present in earlier versions of Node (v6 I think?). As somewhat alluded to in the comment there, this breaks any attempt to truncate (or allocate, in my particular case) a file to more than 2GB.The text was updated successfully, but these errors were encountered: