Fixed compatibility of output.
[AROS.git] / test / exec / copymem.c
blob94f850405cf1e33012323b64f52d8af27a23b526
1 /*
2 Copyright © 1995-2012, The AROS Development Team. All rights reserved.
3 $Id$
4 */
6 #include <stdio.h>
7 #include <string.h>
8 #include <proto/exec.h>
9 #include <proto/dos.h>
10 #include <aros/debug.h>
12 int main(void)
14 while(!CheckSignal(SIGBREAKF_CTRL_C))
16 int size;
17 for(size = 5000; size < 6000; size++)
19 UBYTE *mem = AllocMem(size,MEMF_ANY);
20 UBYTE *mem2 = AllocMem(size,MEMF_ANY);
22 if (mem && mem2)
24 int i;
25 for(i = 0; i < 10; i++)
27 //Forbid();
28 CopyMem(mem, mem2, size);
29 //Permit();
31 if (memcmp(mem, mem2, size))
33 kprintf("=== memcmp failure!!\n");
34 //asm volatile("int3");
38 else
40 kprintf("== out of mem\n");
42 FreeMem(mem, size);
43 FreeMem(mem2, size);
46 kprintf("== exit\n");
47 return 0;