configASSERT( pxLink->pxNextFreeBlock == NULL );

yukunduan wrote on Thursday, October 22, 2015:

Why my project stop in this assert:configASSERT( pxLink->pxNextFreeBlock == NULL );
It,s in vPortFree.

yukunduan wrote on Thursday, October 22, 2015:

This is the debug massage:

yukunduan wrote on Thursday, October 22, 2015:

rtel wrote on Thursday, October 22, 2015:

…because the block being freed was either not first allocated by pvPortMalloc(), or was allocated by pvPortMalloc() but has since been corrupted, or was allocated by pvPortMalloc() but has already been freed.

In all cases - it means the block you are trying to free is not valid.

yukunduan wrote on Thursday, October 22, 2015:

The photo is much to big.Please look it in the new title bar or save in the local.

heinbali01 wrote on Thursday, October 22, 2015:

the block you are trying to free is not valid

It may be helpful to look at the call-stack when the ASSERT is entered. Look at what place you’re freeing a memory block. Check if you have freed it already.

Or maybe you’re freeing an uninitialised pointer?

If not, things are a bit more complex. You will have to see if there is code writing outside a given space. Especially code that write in the heap space is suspect. Check all parameters of memset() and memcpy().

Regards.

yukunduan wrote on Friday, October 23, 2015:

Oh,maybe the problem is I delete some tasks doubly.