Page 1 of 1

os_malloc and os_zallc HANGs forever and Triggers WDT

Posted: Sun Mar 10, 2019 7:45 am
by AgentSmithers
Hi Everyone, Anyone knows the underlying reason on why or how malloc and zalloc hang when exhausted out of memory vs. returning NULL or failure. It's hanging at that point then the WDT kicks off and if I disable the WDT both Software and Hardware it hangs forever and never returns. I was hoping it just needed more time to run logic to find space to allocate however that is not the issue. Any insight would be extremely helpful! :)
Thank you!!

Re: os_malloc and os_zallc HANGs forever and Triggers WDT

Posted: Tue Mar 12, 2019 7:41 am
by AgentSmithers
I found the issue. After many burned hours I found that a buffer overflow was occurring.. To recreate the WDT issue, Alloc 8 bytes, write 9 then alloc again.. should hang indef due to a boundary pointer more than likely being overwritten.
:(