]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Darwin regtest: fix building on older OS versions
authorPaul Floyd <pjfloyd@wanadoo.fr>
Sat, 1 Apr 2023 18:55:22 +0000 (20:55 +0200)
committerPaul Floyd <pjfloyd@wanadoo.fr>
Sat, 1 Apr 2023 18:55:22 +0000 (20:55 +0200)
aligned_alloc was added to macOS 10.15 and 10.13 is the latest
that we support.

memcheck/tests/memalign_args.c
memcheck/tests/memalign_args.stderr.exp
memcheck/tests/memalign_args.stderr.exp-glibc

index 0946a6ce98844b45e4bab61e3cf7d3feec5e9e4b..9c774d61eecfd97da2bc38b7aa3208504d752c8f 100644 (file)
@@ -23,8 +23,10 @@ int main(void)
    res = posix_memalign((void **)&mem,align,size);
    free(mem);
    
+#if !defined(VGO_darwin)
    p = aligned_alloc(align, size);
    free(p);
+#endif
    
    p = valloc(size);
    free(p);
index 4d426d3696681f910e62f55d29eea57680bef5cb..548279887547cf39bd63e0a1d83a99599c28420d 100644 (file)
@@ -8,8 +8,8 @@ Conditional jump or move depends on uninitialised value(s)
 
 Conditional jump or move depends on uninitialised value(s)
    at 0x........: aligned_alloc (vg_replace_malloc.c:...)
-   by 0x........: main (memalign_args.c:26)
+   by 0x........: main (memalign_args.c:27)
 
 Conditional jump or move depends on uninitialised value(s)
    at 0x........: valloc (vg_replace_malloc.c:...)
-   by 0x........: main (memalign_args.c:29)
+   by 0x........: main (memalign_args.c:31)
index 810619639154ceef8ac70c38f6d9b2c0dfaa4059..30cc1dc923988ddd34fd0bc893e5d4a7b75f4e2e 100644 (file)
@@ -8,8 +8,8 @@ Conditional jump or move depends on uninitialised value(s)
 
 Conditional jump or move depends on uninitialised value(s)
    at 0x........: memalign (vg_replace_malloc.c:...)
-   by 0x........: main (memalign_args.c:26)
+   by 0x........: main (memalign_args.c:27)
 
 Conditional jump or move depends on uninitialised value(s)
    at 0x........: valloc (vg_replace_malloc.c:...)
-   by 0x........: main (memalign_args.c:29)
+   by 0x........: main (memalign_args.c:31)