[syslinux] [PATCH 2/2] core: Fix stack overflow when reloading config
H. Peter Anvin
hpa at zytor.com
Thu Jan 21 18:37:19 PST 2016
On 01/21/16 18:33, Celelibi wrote:
>
> BTW, this code is due to Matt Flemming with commit 3a316db1 (later
> modified). The commit log say this:
> ldlinux: Loading a config file should cause re-initialisation
>
> There are a number of initialisation steps that need to be performed
> *every* time a config file is loaded. Reload ldlinux.c32 so that we
> can re-initialise the environment whenever a new config file is
> loaded. This involves unloading all the modules that have been loaded
> since ldlinux.c32. Luckily the list of loaded modules is sorted by
> load order, which means it's trivial to "pop" them from the front of
> the list.
>
Yes, it is the easy way to initialize. Part of me wonders if we should
keep a copy of the data section and just wipe it out.
-hpa
More information about the Syslinux
mailing list