summaryrefslogtreecommitdiff
path: root/regress
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2008-03-24 16:07:38 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2008-03-24 16:07:38 +0000
commit6e48c70f167662c7aec42af9bafc316e322ef92a (patch)
treee8d60920aa020d4ce889b53c2d6a0a1d97090dfc /regress
parent4090672af430e6add8a7d16402dd8db197c65b28 (diff)
We were led astray (like many others before us) to believe that
msg_controllen should be CMSG_LEN() instead of CMSG_SPACE() because the kernel fd passing code was erroring out when "cm->cmsg_len != control->m_len" instead of "CMSG_ALIGN(cm->cmsg_len) != control->m_len". On machines with 16-byte alignment, when one thinks about how the ALIGN padding happens, it is clear that msg_controllen has to be CMSG_SPACE() or the kernel cannot hope to bounds check the messages correctly. For now, change the check to cm->cmsg_len > control->m_len to permit the old ABI to continue working. Later perhaps when all the old binaries are gone we can stop permitting their use. lots of discussion with kettenis
Diffstat (limited to 'regress')
0 files changed, 0 insertions, 0 deletions