Linux: Increase maxBuffer limit to 128 MiB
This commit is contained in:
parent
ebb21118e6
commit
0ba8cf0b27
1 changed files with 5 additions and 2 deletions
7
index.js
7
index.js
|
@ -22,7 +22,7 @@ function Attempt(instance, end) {
|
||||||
command.push('--');
|
command.push('--');
|
||||||
command.push(instance.command);
|
command.push(instance.command);
|
||||||
command = command.join(' ');
|
command = command.join(' ');
|
||||||
Node.child.exec(command,
|
Node.child.exec(command, { maxBuffer: MAX_BUFFER },
|
||||||
function(error, stdout, stderr) {
|
function(error, stdout, stderr) {
|
||||||
if (/sudo: /i.test(stderr)) {
|
if (/sudo: /i.test(stderr)) {
|
||||||
if (platform === 'linux') {
|
if (platform === 'linux') {
|
||||||
|
@ -125,7 +125,7 @@ function Linux(instance, end) {
|
||||||
}
|
}
|
||||||
command.push(instance.command);
|
command.push(instance.command);
|
||||||
command = command.join(' ');
|
command = command.join(' ');
|
||||||
Node.child.exec(command,
|
Node.child.exec(command, { maxBuffer: MAX_BUFFER },
|
||||||
function(error, stdout, stderr) {
|
function(error, stdout, stderr) {
|
||||||
if (error) {
|
if (error) {
|
||||||
if (/No authentication agent found/.test(stderr)) {
|
if (/No authentication agent found/.test(stderr)) {
|
||||||
|
@ -602,3 +602,6 @@ var APPLET = 'UEsDBAoAAAAAAO1YcEcAAAAAAAAAAAAAAAAJABwAQ29udGVudHMvVVQJAAPNnElWLZ
|
||||||
|
|
||||||
var PERMISSION_DENIED = 'User did not grant permission.';
|
var PERMISSION_DENIED = 'User did not grant permission.';
|
||||||
var NO_POLKIT_AGENT = 'No polkit authentication agent found.';
|
var NO_POLKIT_AGENT = 'No polkit authentication agent found.';
|
||||||
|
|
||||||
|
// See issue 66:
|
||||||
|
var MAX_BUFFER = 134217728;
|
||||||
|
|
Loading…
Reference in a new issue