提交 f8aa1572 编写于 作者: B Bernd Edlinger 提交者: Rich Salz

Check that async_jobs is not negative and not too high.

Reviewed-by: NMatt Caswell <matt@openssl.org>
Reviewed-by: NRich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2693)
上级 607c9268
......@@ -1214,7 +1214,7 @@ int speed_main(int argc, char **argv)
#ifndef NO_FORK
int multi = 0;
#endif
int async_jobs = 0;
unsigned int async_jobs = 0;
#if !defined(OPENSSL_NO_RSA) || !defined(OPENSSL_NO_DSA) \
|| !defined(OPENSSL_NO_EC)
long rsa_count = 1;
......@@ -1393,6 +1393,12 @@ int speed_main(int argc, char **argv)
prog);
goto opterr;
}
if (async_jobs > 99999) {
BIO_printf(bio_err,
"%s: too many async_jobs\n",
prog);
goto opterr;
}
#endif
break;
case OPT_MISALIGN:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册