[PATCH] Add netlink domain sockets support to socketutils

Dmitry V. Levin ldv at altlinux.org
Sun May 15 13:23:31 UTC 2016


On Sun, May 15, 2016 at 10:24:22AM +0000, Fabien Siron wrote:
[...]
> > > +     } req = {
> > > +             .nlh = {
> > > +                     .nlmsg_len = sizeof(req),
> > > +                     .nlmsg_type = SOCK_DIAG_BY_FAMILY,
> > > +                     .nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
> > > +             },
> > > +             .idr = {
> > > +                     .sdiag_family = AF_NETLINK,
> > > +                     .sdiag_protocol = NDIAG_PROTO_ALL,
> > > +                     .ndiag_ino = (unsigned) inode,
> > 
> > Isn't implicit cast enough?
> > 
> > BTW, inode lookup is not implemented anyway, so like in case of
> > unix_send_query, .ndiag_ino initialization has no practical purpose.
> 
> Do you suggest to remove .ndiag_ino initialization?

Yes, unless you want to leave it as a reminder of unimplemented kernel
feature.


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20160515/c6863506/attachment.bin>


More information about the Strace-devel mailing list