diff --git a/src/lib/commits.js b/src/lib/commits.js index cbb2d537..377e504f 100644 --- a/src/lib/commits.js +++ b/src/lib/commits.js @@ -49,6 +49,9 @@ module.exports = function (config, cb) { function extract () { exec( 'git log -E --format=%H==SPLIT==%B==END== ' + range, + { + maxBuffer: 1024 * 1024 // 1MB instead of 220KB (issue #286) + }, function (err, stdout) { if (err) return cb(err) diff --git a/test/mocks/child-process.js b/test/mocks/child-process.js index 123f5b37..87b68bea 100644 --- a/test/mocks/child-process.js +++ b/test/mocks/child-process.js @@ -4,7 +4,10 @@ const rawCommits = [ ] module.exports = { - exec: function (command, cb) { + exec: function (command, options, cb) { + if (typeof cb === 'undefined' && typeof options === 'function') { + cb = options + } if (/contains/.test(command)) { if (/notinhistory/.test(command)) return cb(new Error()) return cb(null, 'whatever\nmaster\n')