Socket
Socket
Sign inDemoInstall

machinepack-process

Package Overview
Dependencies
3
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.0 to 1.2.1

34

machines/spawn.js

@@ -88,19 +88,21 @@ module.exports = {

}
if (err.syscall==='spawn') {
if (err.code==='ENOTDIR') {
return exits.notADir();
}
if (err.code==='ENOENT') {
return exits.noSuchDir();
}
if (err.code==='EACCES') {
return exits.forbidden();
}
// console.log('err=>',err);
// console.log('keys=>',Object.keys(err));
// console.log('err.code=>',err.code);
// console.log('err.killed=>',err.killed);
// console.log('err.syscall=>',err.syscall);
// console.log('err.errno=>',err.errno); // e.g. 127 || 'ENOENT'
// console.log('err.signal=>',err.signal); // e.g. 'SIGTERM'
// `err.syscall.match(/spawn/i)` should be true as well, but not testing since
// Node v0.12 changed this a bit and we want to future-proof ourselves if possible.
if (err.code==='ENOTDIR') {
return exits.notADir();
}
// console.log('errno',err.errno);
// console.log('syscall',err.syscall);
// console.log(_.keys(err));
// console.log(err.stack);
// console.log('err code: ' + err.code); // e.g. 127 || 'ENOENT'
// console.log('Signal received: ' + err.signal); // e.g. 'SIGTERM'
if (err.code==='ENOENT') {
return exits.noSuchDir();
}
if (err.code==='EACCES') {
return exits.forbidden();
}
return exits.error(err);

@@ -107,0 +109,0 @@ }

{
"name": "machinepack-process",
"version": "1.2.0",
"version": "1.2.1",
"description": "Work with child procs and the running process.",

@@ -5,0 +5,0 @@ "scripts": {

@@ -13,4 +13,11 @@ {

}
},
{
"using": {
"command": "echo hi",
"dir": "/place/that/totally/doesnt/exist"
},
"outcome": "noSuchDir"
}
]
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc