On Mon, 7 Nov 2022 22:04:55 GMT, Alexander Zuev <[email protected]> wrote:

> Removed the additional multiplication overflow detection.
> Instead cast all the parameters to type_t just the way they are treated in 
> the existing size check macro. 
> This way there is no possibility to accidentally provide parameters that will 
> pass the size check macro while being cast to size_t there but then due to 
> the missing cast cause the wrong size passed the actual allocation function.
> Since this checking macro was used in couple of different places all of them 
> needs to be updated in the similar way.

This pull request has now been integrated.

Changeset: 84e12244
Author:    Alexander Zuev <[email protected]>
URL:       
https://git.openjdk.org/jdk/commit/84e12244a4ff82b3307a5ffe6fbe9dded7b08d86
Stats:     11 lines in 1 file changed: 0 ins; 4 del; 7 mod

8296496: Overzealous check in sizecalc.h prevents large memory allocation

Reviewed-by: aivanov, azvegint

-------------

PR: https://git.openjdk.org/jdk/pull/11030

Reply via email to