fix malloc-brk-fail
[libc-test] / src / functional / string_memset.c
index c85ade2..e688742 100644 (file)
@@ -3,7 +3,7 @@
 #include <stdint.h>
 #include "test.h"
 
-#define N 400
+#define N 500
 static char buf[N];
 static char buf2[N];
 
@@ -11,7 +11,7 @@ static void *(*volatile pmemset)(void *, int, size_t);
 
 static char *aligned(void *p)
 {
-       return (char*)(((uintptr_t)p + 63) & -64U);
+       return (char*)(((uintptr_t)p + 63) & -64);
 }
 
 static void test_align(int align, int len)
@@ -57,8 +57,8 @@ int main(void)
 
        pmemset = memset;
 
-       for (i = 0; i < 16; i++)
-               for (j = 0; j < 200; j++)
+       for (i = 0; i < 64; i++)
+               for (j = 0; j < N-256; j++)
                        test_align(i,j);
 
        test_value('c');