[syslinux] [PATCH 2/2] core: Fix stack overflow when reloading config

Celelibi celelibi at gmail.com
Tue Jan 26 06:55:26 PST 2016


2016-01-25 21:03 UTC+01:00, H. Peter Anvin <hpa at zytor.com>:
> On 01/25/16 10:51, Celelibi wrote:
>>
>> Do you suggest to do this only for ldlinux.c32?
>>
>> If we keep a copy only of the data section, we will only be able to
>> use it when we know we reload the module. So it will only apply to
>> ldlinux.c32. While most modules could benefit from this as the new
>> config file will probably reload the same menu and libraries.
>>
>
> Libraries shouldn't need it; they can simply stay in memory.  For
> executables one could do such initialization before invoking the entry
> point.
>
> 	-hpa

Do you mean executables should also stay in memory and just get a
fast-reinitialization when re-running them?

However, unless we do something more heavy-weight, when a config file
is loaded, I guess all modules will have to be unloaded anyway since
the search path can be changed by the new config file and other
modules with the same name can be loaded.

BTW, can ldlinux.c32 be affected by the PATH directive or another
configuration option?


Celelibi


More information about the Syslinux mailing list