Re:The Linux Kernel Is Now VLA (Variable-Length Array) Free
by drfuchs on Monday October 29, 2018 @09:17AM
(#18327239)
You'd have to get longjmp to understand how to unwind these heap-allocated arrays, not only from the current function's stack frame, but for all the ones in the longjmp'd-over frames. In C-land, longjmp simply overwrites the stack pointer (and all other registers), which implicitly "deallocates" all the VLA arrays, and all alloca() allocations, in one fell swoop. There is no notion of a step-by-step unwinding of the stack, so it would be a big task to try to trap all intermediate VLA arrays.
[ Parent
| on HN ]
There are no comments on this comment yet.