[Bug 217610] ELF loader should have a special case for program headers with p_filesz == 0

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Mar 7 19:32:20 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=217610

--- Comment #4 from Konstantin Belousov <kib at FreeBSD.org> ---
Created attachment 180607
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=180607&action=edit
Handle filsz == 0.

Attached is the proposed patch.  Note that it is somewhat more involved that
just passing the filsz == 0 in the initial ENOEXEC check, because I do not want
even think what happens when offset is not multiple of the page size.  I just
force any file-backed COW mappings to be avoided if filesz == 0.

Also the patch contains some style cleanup, which I split for actual commit.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list