mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
moved building of execOpt object to line 36
This commit is contained in:
parent
06adf3d346
commit
d25e027201
@ -33,7 +33,10 @@ module.exports = function(RED) {
|
||||
this.oldrc = (n.oldrc || false).toString();
|
||||
var node = this;
|
||||
|
||||
var cleanup = function(p) {
|
||||
var execOpt = {encoding:'binary', maxBuffer:10000000};
|
||||
if (process.platform === 'linux' && fs.existsSync('/bin/bash')) { execOpt.shell = '/bin/bash'; }
|
||||
|
||||
var cleanup = function(p) {
|
||||
node.activeProcesses[p].kill();
|
||||
//node.status({fill:"red",shape:"dot",text:"timeout"});
|
||||
//node.error("Exec node timeout");
|
||||
@ -123,8 +126,6 @@ module.exports = function(RED) {
|
||||
});
|
||||
}
|
||||
else {
|
||||
var execOpt = {encoding:'binary', maxBuffer:10000000};
|
||||
if (process.platform === 'linux' && fs.existsSync('/bin/bash')) { execOpt.shell = '/bin/bash'; }
|
||||
var cl = node.cmd;
|
||||
if ((node.addpay === true) && msg.hasOwnProperty("payload")) { cl += " "+msg.payload; }
|
||||
if (node.append.trim() !== "") { cl += " "+node.append; }
|
||||
|
Loading…
Reference in New Issue
Block a user