[PATCH v1 02/11] netlink: print unrecognized attribute data in hex
Dmitry V. Levin
ldv at altlinux.org
Thu Jul 6 12:03:56 UTC 2017
On Thu, Jul 06, 2017 at 09:57:28AM +0800, JingPiao Chen wrote:
> * nlattr.c (decode_nlattr_with_data): Replace printstrn
> with printstr_ex and set QUOTE_FORCE_HEX flag.
Perhaps in other cases of netlink decoder where printstrn is used
(except decode_nla_strn) QUOTE_FORCE_HEX is more appropriate, too.
$ grep printstrn netlink.c netlink_sock_diag.c nlattr.c
netlink.c: printstrn(tcp, addr, len);
netlink.c: printstrn(tcp, addr, len);
netlink.c: printstrn(tcp, addr, len);
netlink_sock_diag.c: printstrn(tcp, addr + sizeof(family),
nlattr.c: printstrn(tcp, addr, len);
nlattr.c: printstrn(tcp, addr + NLA_HDRLEN, len - NLA_HDRLEN);
nlattr.c: printstrn(tcp, addr, len);
You don't have to squash all these changes into a single commit, though.
--
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20170706/db8729cf/attachment.bin>
More information about the Strace-devel
mailing list