write-file-atomic
Advanced tools
Comparing version 2.4.2 to 2.4.3
@@ -0,1 +1,6 @@ | ||
# 2.4.3 | ||
* Ignore errors raised by `fs.closeSync` when cleaning up after a write | ||
error. | ||
# 2.4.2 | ||
@@ -2,0 +7,0 @@ |
@@ -212,3 +212,2 @@ 'use strict' | ||
try { | ||
fd = fs.openSync(tmpfile, 'w', options.mode) | ||
@@ -229,3 +228,9 @@ if (Buffer.isBuffer(data)) { | ||
} catch (err) { | ||
if (fd) fs.closeSync(fd) | ||
if (fd) { | ||
try { | ||
fs.closeSync(fd) | ||
} catch (ex) { | ||
// ignore close errors at this stage, error may have closed fd already. | ||
} | ||
} | ||
removeOnExitHandler() | ||
@@ -232,0 +237,0 @@ cleanup() |
{ | ||
"name": "write-file-atomic", | ||
"version": "2.4.2", | ||
"version": "2.4.3", | ||
"description": "Write files in an atomic fashion w/configurable ownership", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "standard && tap --100 test/*.js" | ||
"test": "standard && tap --100 test/*.js", | ||
"preversion": "npm test", | ||
"postversion": "npm publish", | ||
"postpublish": "git push origin --follow-tags" | ||
}, | ||
@@ -9,0 +12,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12243
224
1