Skip to content
Snippets Groups Projects
Commit 229a6dbd authored by Richard Biener's avatar Richard Biener
Browse files

middle-end/100547 - check rtvec_alloc size

This makes the rtvec_alloc argument size_t catching overflow and
truncated arguments (from "invalid" testcases), verifying the
argument against INT_MAX which is the limit set by the int
typed rtvec_def.num_elem member.

2021-05-12  Richard Biener  <rguenther@suse.de>

	PR middle-end/100547
	* rtl.h (rtvec_alloc): Make argument size_t.
	* rtl.c (rtvec_alloc): Verify the count is less than INT_MAX.
parent 19040050
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment