Skip to content

Commit

Permalink
Merge pull request OpenAPITools#16 from gervasiocaj/patch-1
Browse files Browse the repository at this point in the history
Fixes shell buffer overflow for large input specs
  • Loading branch information
kay-schecker authored Jul 5, 2019
2 parents adc5be3 + c676d15 commit a16383a
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions bin/openapi-generator
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env node

const {exec} = require('child_process');
const {spawn} = require('child_process');
const {resolve} = require('path');

const args = process.argv.slice(2);
Expand All @@ -13,7 +13,5 @@ if (args) {
command += ` ${args.join(' ')}`;
}

const cmd = exec(command);
cmd.stdout.pipe(process.stdout);
cmd.stderr.pipe(process.stderr);
const cmd = spawn(command, { stdio: 'inherit', shell: true });
cmd.on('exit', process.exit);

0 comments on commit a16383a

Please sign in to comment.