On Thu, Jun 15, 2017 at 11:39:34AM +0200, Miroslav Lichvar wrote: > On Thu, Jun 15, 2017 at 12:17:43PM +0300, Dmitry V. Levin wrote: > > On Thu, Jun 15, 2017 at 10:54:59AM +0200, Miroslav Lichvar wrote: > > > > What do you think these functions should print in case the data size > > > > is smaller than necessary? > > > > > > Nothing. Is there a better option? > > > > If you print nothing, you'd end up with this on x86_64: > > msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_TIMESTAMP, > > cmsg_data=}] > > It doesn't look nice, does it? > > It does not, but it's not likely anyone will ever see it, right? :)
:) > Would "cmsg_data=?" be better? It looks better. Thinking of potential use, maybe these functions should also return a boolean status indicating whether the printing was successful. -- ldv
signature.asc
Description: PGP signature
------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________ Strace-devel mailing list Strace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/strace-devel