Skip to content

Commit 2ab92ae

Browse files
committed
feedback
1 parent a23813c commit 2ab92ae

1 file changed

Lines changed: 9 additions & 10 deletions

File tree

scripts/fuzz_shell.js

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,17 @@ var exportsToCall;
5454
// get the same behavior from split modules as before the split.
5555
var fuzzSplit = false;
5656

57-
while (argv.length > 0) {
58-
var last = argv[argv.length - 1];
59-
if (last.startsWith('exports:')) {
60-
exportsToCall = last.substr('exports:'.length).split(',');
61-
argv.pop();
62-
continue;
63-
} else if (last == '--fuzz-split') {
57+
for (var i = 0; i < argv.length; i++) {
58+
var curr = argv[i];
59+
if (curr.startsWith('exports:')) {
60+
exportsToCall = curr.substr('exports:'.length).split(',');
61+
argv.splice(i, 1);
62+
i--;
63+
} else if (curr == '--fuzz-split') {
6464
fuzzSplit = true;
65-
argv.pop();
66-
continue;
65+
argv.splice(i, 1);
66+
i--;
6767
}
68-
break;
6968
}
7069

7170
// If a second parameter is given, it is a second binary that we will link in

0 commit comments

Comments
 (0)