forked from Imagelibrary/rtems
stackchk: Remove heap hack
It is now guranteed that threads do not use a freed stack during termination.
This commit is contained in:
@@ -113,14 +113,8 @@ static inline bool Stack_check_Frame_pointer_in_range(
|
|||||||
((_the_stack)->area)
|
((_the_stack)->area)
|
||||||
|
|
||||||
#else
|
#else
|
||||||
/*
|
|
||||||
* We need this magic offset because during a task delete the task stack will
|
|
||||||
* be freed before we enter the task switch extension which checks the stack.
|
|
||||||
* The task stack free operation will write the next and previous pointers
|
|
||||||
* for the free list into this area.
|
|
||||||
*/
|
|
||||||
#define Stack_check_Get_pattern( _the_stack ) \
|
#define Stack_check_Get_pattern( _the_stack ) \
|
||||||
((char *)(_the_stack)->area + sizeof(Heap_Block) - HEAP_BLOCK_HEADER_SIZE)
|
((char *)(_the_stack)->area)
|
||||||
|
|
||||||
#define Stack_check_Calculate_used( _low, _size, _high_water) \
|
#define Stack_check_Calculate_used( _low, _size, _high_water) \
|
||||||
( ((char *)(_low) + (_size)) - (char *)(_high_water) )
|
( ((char *)(_low) + (_size)) - (char *)(_high_water) )
|
||||||
|
|||||||
Reference in New Issue
Block a user