Hi all,
I have problem by allocating a memory for my objects. Assuming this lines
1- object* test;
2- test = new object ;
3- test->Attribute = true
4- ....
5- delete test;
if i repeat this code several times then I get error by allocating the memory in line 2
The error that i got is:
test-project: malloc.c:3096: sYSMALLOc: Assertion `(old_top == (((mbinptr) (((char *) &((av)->bins[((1) - 1) * 2])) - __builtin_offsetof (struct malloc_chunk, fd)))) && old_size == 0) || ((unsigned long) (old_size) >= (unsigned long)((((__builtin_offsetof (struct malloc_chunk, fd_nextsize))+((2 * (sizeof(size_t))) - 1)) & ~((2 * (sizeof(size_t))) - 1))) && ((old_top)->size & 0x1) && ((unsigned long)old_end & pagemask) == 0)' failed.
May someone clarify me why the simulation is aborted by allocating memory through new operator?
thanks in advance..