branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9549
# Anonymise line numbers in mc_replace_strmem.c
sed "s/mc_replace_strmem.c:[0-9]*/mc_replace_strmem.c:.../" |
-# Remove the size in "The main thread stack size..." message.
-sed "s/The main thread stack size used in this run was [0-9]*/The main thread stack size used in this run was .../" |
-
# Replace exit_group() with exit(), because you can get either on Linux
# depending on the system.
perl -p -e "s/param exit_group\(status\)/param exit(status)/" |
args.stderr.exp args.stdout.exp args.vgtest \
async-sigs.stderr.exp async-sigs.stdout.exp async-sigs.vgtest \
bitfield1.stderr.exp bitfield1.vgtest \
- blockfault.vgtest blockfault.stderr.exp blockfault.stdout.exp \
bug129866.vgtest bug129866.stderr.exp bug129866.stdout.exp \
closeall.stderr.exp closeall.vgtest \
cmdline0.stderr.exp cmdline0.stdout.exp cmdline0.vgtest \
check_PROGRAMS = \
ansi args \
- async-sigs bitfield1 blockfault \
+ async-sigs bitfield1 \
bug129866 \
closeall coolo_strlen \
discard exec-sigmask execve faultstatus fcntl_setown \
# Remove "Nulgrind, ..." line and the following copyright line.
sed "/^Nulgrind, a binary JIT-compiler./ , /./ d" |
-# Remove the size in "The main thread stack size..." message.
-sed "s/The main thread stack size used in this run was [0-9]*/The main thread stack size used in this run was .../" |
-
# Anonymise addresses
$dir/../../tests/filter_addresses
noinst_SCRIPTS = filter_stderr
EXTRA_DIST = $(noinst_SCRIPTS) \
+ blockfault.stderr.exp blockfault.vgtest \
mremap.stderr.exp mremap.stdout.exp mremap.vgtest \
mremap2.stderr.exp mremap2.stdout.exp mremap2.stdout.exp2 \
mremap2.stdout.exp-glibc28-amd64 mremap2.vgtest
check_PROGRAMS = \
+ blockfault \
mremap \
mremap2
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
+#include "tests/sys_mman.h"
static void handler(int sig, siginfo_t *info, void *v)
{
the default handler */
int main()
{
-#if defined(_AIX)
- printf("this test hangs when run (even natively) on AIX\n");
- return 0;
-#endif
+ int* unmapped_page = get_unmapped_page();
struct sigaction sa;
sigset_t mask;
sigfillset(&mask);
sigprocmask(SIG_BLOCK, &mask, NULL);
- *(volatile int *)12345 = 213;
+ *(volatile int *)unmapped_page = 213;
return 0;
}
Process terminating with default action of signal 11 (SIGSEGV)
Access not within mapped region at address 0x........
- at 0x........: main (blockfault.c:32)
+ at 0x........: main (blockfault.c:30)
If you believe this happened as a result of a stack overflow in your
program's main thread (unlikely but possible), you can try to increase
the size of the main thread stack using the --main-stacksize= flag.
# Remove any ": dumping core" message as the user might have a
# limit set that prevents the core dump
-sed "s/\(signal [0-9]* (SIG[A-Z]*)\): dumping core/\1/"
+sed "s/\(signal [0-9]* (SIG[A-Z]*)\): dumping core/\1/" |
+
+# Remove the size in "The main thread stack size..." message.
+sed "s/The main thread stack size used in this run was [0-9]*/The main thread stack size used in this run was .../"
+