Skip to content
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: fixup negative length in fs.truncate #37483

Closed
wants to merge 3 commits into from

Commits on Feb 23, 2021

  1. fs: fixup negative length in fs.truncate

    `fs.ftruncate`, `fsPromises.truncate`, and `fsPromises.ftruncate`
    all adjust negative lengths to 0 before invoking the system call.
    `fs.truncate()` was the one outlier.
    
    This "fixes" nodejs#35632 but in the
    opposite direction than discussed in the issue -- specifically by
    removing an EINVAL error from one function rather than adding it to
    another.
    
    Signed-off-by: James M Snell <jasnell@gmail.com>
    Fixes: nodejs#35632
    jasnell committed Feb 23, 2021
    Configuration menu
    Copy the full SHA
    036c6f4 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    bb31653 View commit details
    Browse the repository at this point in the history
  3. [Squash] typo

    Co-authored-by: Darshan Sen <raisinten@gmail.com>
    jasnell and RaisinTen committed Feb 23, 2021
    Configuration menu
    Copy the full SHA
    4c8786c View commit details
    Browse the repository at this point in the history