Github user dblotsky commented on a diff in the pull request:

    https://github.com/apache/cordova-android/pull/180#discussion_r31978041
  
    --- Diff: bin/templates/cordova/lib/exec.js ---
    @@ -19,16 +19,42 @@
            under the License.
     */
     
    -var child_process = require('child_process'),
    -    Q       = require('q');
    +var child_process = require('child_process');
    +var Q             = require('q');
    +
    +// constants
    +var DEFAULT_MAX_BUFFER = 1024000;
     
     // Takes a command and optional current working directory.
     // Returns a promise that either resolves with the stdout, or
     // rejects with an error message and the stderr.
    -module.exports = function(cmd, opt_cwd) {
    +//
    +// WARNING:
    +//         opt_cwd is an artifact of an old design, and must
    +//         be removed in the future; the correct solution is
    +//         to pass the options object the same way that
    +//         child_process.exec expects
    +//
    +// NOTE:
    +//      exec documented here - 
https://nodejs.org/api/child_process.html#child_process_child_process_exec_command_options_callback
    +module.exports = function(cmd, opt_cwd, options) {
    +
         var d = Q.defer();
    +
    +    if (options === undefined) {
    +        options = {};
    --- End diff --
    
    Previously, a hard-coded `maxBuffer` was always passed to 
`child_process.exec`. Now, it's passed as a default when it's not specified in 
a given `options.maxBuffer`. Otherwise, the given value is respected.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to