]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fortran: improve error recovery on invalid array section
authorHarald Anlauf <anlauf@gmx.de>
Wed, 9 Mar 2022 20:58:26 +0000 (21:58 +0100)
committerHarald Anlauf <anlauf@gmx.de>
Mon, 16 May 2022 19:53:50 +0000 (21:53 +0200)
commit6b8cd1fb402163e16d2a139f4bee346ff0c8f234
tree97c3b574ac70b220550e3f60078a5242ea57f6f9
parentf43db17894744827d93ddcea7952d4ecf1f83f30
Fortran: improve error recovery on invalid array section

gcc/fortran/ChangeLog:

PR fortran/104849
* expr.c (find_array_section): Avoid NULL pointer dereference on
invalid array section.

gcc/testsuite/ChangeLog:

PR fortran/104849
* gfortran.dg/pr104849.f90: New test.

(cherry picked from commit 22015e77d3e45306077396b9de8a8a28bb67fb20)
gcc/fortran/expr.c
gcc/testsuite/gfortran.dg/pr104849.f90 [new file with mode: 0644]