lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1300112100.3423.24.camel@edumazet-laptop>
Date:	Mon, 14 Mar 2011 15:15:00 +0100
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Kurt Van Dijck <kurt.van.dijck@....be>
Cc:	socketcan-core@...ts.berlios.de, netdev@...r.kernel.org
Subject: Re: [RFC v3 1/6] can: extend sockaddr_can to include j1939 members

Le lundi 14 mars 2011 à 14:24 +0100, Kurt Van Dijck a écrit :

> +/*
> + * required_size
> + * macro to find the minimum size of a struct
> + * that includes a requested member
> + */
> +#define required_size(member, struct_type) \
> +	(offsetof(typeof(struct_type), member) + \
> +	 sizeof(((typeof(struct_type) *)(0))->member))
> +

Hmm, most similar macros reverse arguments.

(For example : offsetof())

What about

#define required_size(TYPE, MEMBER) ...



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ