diff --git a/benchmark/common.js b/benchmark/common.js index 511ae384f418bf..c0c7805a5c53db 100644 --- a/benchmark/common.js +++ b/benchmark/common.js @@ -188,11 +188,13 @@ function parseOpts(options) { var num = keys.length; var conf = {}; for (var i = 2; i < process.argv.length; i++) { - var match = process.argv[i].match(/^(.+)=(.+)$/); - if (!match || !match[1] || !match[2] || !options[match[1]]) { + var match = process.argv[i].match(/^(.+)=(.*)$/); + if (!match || !match[1] || !options[match[1]]) { return null; } else { - conf[match[1]] = isFinite(match[2]) ? +match[2] : match[2] + conf[match[1]] = (match[2].length && isFinite(match[2]) + ? +match[2] + : match[2]); num--; } }