]> gcc.gnu.org Git - gcc.git/commit
testsuite/98002 - fix gcc.dg/strncmp-2.c
authorRichard Biener <rguenther@suse.de>
Thu, 26 Nov 2020 09:07:06 +0000 (10:07 +0100)
committerRichard Biener <rguenther@suse.de>
Tue, 1 Dec 2020 10:37:23 +0000 (11:37 +0100)
commitaf7bd9c22e114de74fa86ec6f40e336ca1319a50
treeb7246491d01f0dc3203ff80560b5ddb30532f29c
parent9d769cdde26d87043da0e1ffdee51010a71f49c2
testsuite/98002 - fix gcc.dg/strncmp-2.c

This makes sure not to free() memory we have mprotected to PROT_NONE
by calling mprotect again with PROT_READ|PROT_WRITE.  This avoids
crashing the allocator when in debug mode.

2020-11-16  Richard Biener  <rguenther@suse.de>

PR testsuite/98002
* gcc.dg/strncmp-2.c: Call mprotect again before free.

(cherry picked from commit 5b3a8fad18324cd38c221bdb0ae2b690fc82ede0)
gcc/testsuite/gcc.dg/strncmp-2.c
This page took 0.055279 seconds and 5 git commands to generate.