Page MenuHomeFreeBSD

imgact_elf: compute auxv buffer size instead of using magic value

Authored by trasz on Jun 19 2021, 11:42 AM.

Diff Detail

rG FreeBSD src repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

This revision is now accepted and ready to land.Jun 19 2021, 1:49 PM

Note that in theory, application might replace its auxv vector with whatever values it wants. So proc_getauxv() does not limit the count to AT_COUNT, but defined somewhat arbitrary PROC_AUXV_MAX limit. You might move this define to some global place and use it instead of AT_COUNT, as a follow-up.

Anyway, this change is already an improvement, since it avoids truncating auxv for normal core dumps.