summaryrefslogtreecommitdiff
path: root/gcc/read-rtl.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2005-02-11 15:09:53 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2005-02-11 15:09:53 +0000
commitc5d97f6e5dd6ec31cceccc5c516bf70c85948669 (patch)
tree5fb965182f3c4a98a305b3e83552e71214696219 /gcc/read-rtl.c
parentf6254da44552dfc0c2b98dcfbd9f3b846976d235 (diff)
downloadgcc-c5d97f6e5dd6ec31cceccc5c516bf70c85948669.tar.gz
read-rtl.c (read_rtx_1): Give fatal error if we see a vector with no elements.
* read-rtl.c (read_rtx_1): Give fatal error if we see a vector with no elements. From-SVN: r94879
Diffstat (limited to 'gcc/read-rtl.c')
-rw-r--r--gcc/read-rtl.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/read-rtl.c b/gcc/read-rtl.c
index c9a3fee81dd..874dd3b36c8 100644
--- a/gcc/read-rtl.c
+++ b/gcc/read-rtl.c
@@ -1253,6 +1253,9 @@ read_rtx_1 (FILE *infile)
memcpy (&return_vec->elem[0], obstack_finish (&vector_stack),
list_counter * sizeof (rtx));
}
+ else if (format_ptr[i] == 'E')
+ fatal_with_file_and_line (infile,
+ "vector must have at least one element");
XVEC (return_rtx, i) = return_vec;
obstack_free (&vector_stack, NULL);
/* close bracket gotten */