cpukit/stackchk: Remove additional offset of SANITY_PATTERN_SIZE_WORDS

This offset is already accounted for by Stack_check_Usable_stack_start()
called from Stack_check_Visit_stack() and adding it a second time can
cause interaction beyond the bounds of the stack.
This commit is contained in:
Kinsey Moore
2024-08-27 14:48:12 -05:00
committed by Kinsey Moore
parent cb0a530503
commit ad51286e2b

View File

@@ -409,7 +409,6 @@ static inline void *Stack_check_Find_high_water_mark(
* match pattern
*/
base += SANITY_PATTERN_SIZE_WORDS;
for (ebase = base + length; base < ebase; base++)
if (*base != U32_PATTERN)
return (void *) base;