Page MenuHomeFreeBSD

Add a missing manual page for the API of socket control message routines for ancillary data access (e.g., CMSG_DATA)
ClosedPublic

Authored by 0mp on Apr 27 2018, 3:14 PM.

Details

Summary

It looks like FreeBSD is missing a manual page for macros defined in sys/sys/socket.h. The man page is present for example in Linux as cmsg(3) and in OpenBSD as CMSG_DATA(3). There's also a nice blog post about FreeBSD SCTP ancillary data by Tsvetomir Dimitrov.

Here's a manual page for CMSG_DATA based on the OpenBSD one. It looks like it does not need much tweaking as the presented information are true on FreeBSD as well. I've added cross references to related manpages and RFCs.

I am not sure about the example though. It does not define all the required variables. To make it less confusing for new users (such as me) I consolidated those OpenBSD examples into one working, compile-and-run example.


Bugzilla: 227777

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Replace void * with unsigned char * in the synopsis of CMSG_DATA.

Reupload the patch using arcanist.

mat added a subscriber: mat.

accepted as your mentor, still need approval from man/src.

This revision is now accepted and ready to land.Jul 19 2018, 11:57 AM

Fix the order of the MAN list in share/man/man3/Makefile.

This revision now requires review to proceed.Aug 1 2018, 12:30 PM

In general, if you change content in a man page (like links), you need to bump the document date (.Dd at the top of the file) to the date of the commit (once it's approved).
If the man page you were importing from another system has local changes that are in FreeBSD only (like examples), you also need to bump the .Dd.
Can you do that for all the man pages in this review? Thank you for doing the work on this man page.

This revision is now accepted and ready to land.Aug 18 2018, 5:38 PM
This revision was automatically updated to reflect the committed changes.

Thank you for your reviews :)