Coverity issues:
https://scan5.scan.coverity.com/#/project-view/60762/10222?selectedIssue=
1677828
and
https://scan5.scan.coverity.com/#/project-view/60762/10222?selectedIssue=
1677827
caught some dead code in the simdutf test.
The total variable is defined as an int, which is tested against <=
INT_MAX, and > INT_MAX, which will always be true, and false
respectively, making the <= test needless, and the condition the latter
bounds dead code
Clean that up.
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Nikola Pajkovsky <nikolap@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/29525)
}
*out = '\0';
}
- while (inl >= ctx->length && total <= INT_MAX) {
+ while (inl >= ctx->length) {
j = evp_encodeblock_int_old(ctx, out, in, ctx->length);
in += ctx->length;
inl -= ctx->length;
}
*out = '\0';
}
- if (total > INT_MAX) {
- /* Too much output data! */
- *outl = 0;
- return 0;
- }
if (inl != 0)
memcpy(&(ctx->enc_data[0]), in, inl);
ctx->num = inl;