diff options
author | bluhm <> | 2019-06-11 22:16:13 +0000 |
---|---|---|
committer | bluhm <> | 2019-06-11 22:16:13 +0000 |
commit | 6be28dc6a94d5924375aa3d5124cd3437ce39e7b (patch) | |
tree | 09316f4f32fd9a2471967dae7083a0ee41e67a81 /src | |
parent | af4bc495bc58925bda45c14a2529602e4c2e3ab1 (diff) | |
download | openbsd-6be28dc6a94d5924375aa3d5124cd3437ce39e7b.tar.gz openbsd-6be28dc6a94d5924375aa3d5124cd3437ce39e7b.tar.bz2 openbsd-6be28dc6a94d5924375aa3d5124cd3437ce39e7b.zip |
Disable junking with malloc options. If set, the test hangs on low
memory arm64 machines.
found by patrick@; OK otto@
Diffstat (limited to 'src')
-rw-r--r-- | src/regress/lib/libc/malloc/malloc_errno/malloc_errno.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/regress/lib/libc/malloc/malloc_errno/malloc_errno.c b/src/regress/lib/libc/malloc/malloc_errno/malloc_errno.c index 896ea3c900..1759291f38 100644 --- a/src/regress/lib/libc/malloc/malloc_errno/malloc_errno.c +++ b/src/regress/lib/libc/malloc/malloc_errno/malloc_errno.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: malloc_errno.c,v 1.4 2003/12/25 18:49:57 miod Exp $ */ | 1 | /* $OpenBSD: malloc_errno.c,v 1.5 2019/06/11 22:16:13 bluhm Exp $ */ |
2 | /* | 2 | /* |
3 | * Public domain. 2003, Otto Moerbeek | 3 | * Public domain. 2003, Otto Moerbeek |
4 | */ | 4 | */ |
@@ -7,6 +7,9 @@ | |||
7 | #include <stdio.h> | 7 | #include <stdio.h> |
8 | #include <stdlib.h> | 8 | #include <stdlib.h> |
9 | 9 | ||
10 | /* On arm64 with 2G of memory this test hangs while junking. */ | ||
11 | char *malloc_options = "jj"; | ||
12 | |||
10 | static void | 13 | static void |
11 | testerrno(size_t sz) | 14 | testerrno(size_t sz) |
12 | { | 15 | { |
@@ -19,7 +22,7 @@ testerrno(size_t sz) | |||
19 | errx(1, "fail: %lx %p %d", (unsigned long)sz, p, errno); | 22 | errx(1, "fail: %lx %p %d", (unsigned long)sz, p, errno); |
20 | 23 | ||
21 | /* if alloc succeeded, test if errno did not change */ | 24 | /* if alloc succeeded, test if errno did not change */ |
22 | if (p != NULL && errno != -1) | 25 | if (p != NULL && errno != -1) |
23 | errx(1, "fail: %lx %p %d", (unsigned long)sz, p, errno); | 26 | errx(1, "fail: %lx %p %d", (unsigned long)sz, p, errno); |
24 | 27 | ||
25 | free(p); | 28 | free(p); |