LKML Archive on
help / color / mirror / Atom feed
* [patch] rename members in dummy _xt_align struct
@ 2007-01-29 22:25 Mike Frysinger
  0 siblings, 0 replies; only message in thread
From: Mike Frysinger @ 2007-01-29 22:25 UTC (permalink / raw)
  To: netfilter, netdev; +Cc: linux-kernel

[-- Attachment #1.1: Type: text/plain, Size: 525 bytes --]

i'd like to rename the members in the _xt_align struct in 
netfilter/x_tables.h ... by not using 'u8', 'u16', etc..., it's possible to 
filter headers meant for userspace through the preprocessor and pull out 
people who accidentally utilize these internal types ... however, by using 
struct members who have the same name as 'u8', 'u16', etc..., this throws up 
a false positive

of all the exported headers, this is the only one to do this sort of thing, so 
i hope you guys wont mind making the change :)

[-- Attachment #1.2: Type: application/pgp-signature, Size: 827 bytes --]

[-- Attachment #2: linux-netfilter-dont-use-type-names.patch --]
[-- Type: text/x-diff, Size: 567 bytes --]

Use diff variable names than the standard type so we can run automated script
checks on the code to easily pull out export violations.

Signed-off-by: Mike Frysinger <>

--- a/include/linux/netfilter/x_tables.h
+++ b/include/linux/netfilter/x_tables.h
@@ -82,10 +84,10 @@ struct xt_get_revision
 struct _xt_align
-	u_int8_t u8;
-	u_int16_t u16;
-	u_int32_t u32;
-	u_int64_t u64;
+	u_int8_t align_u8;
+	u_int16_t align_u16;
+	u_int32_t align_u32;
+	u_int64_t align_u64;
 #define XT_ALIGN(s) (((s) + (__alignof__(struct _xt_align)-1)) 	\

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-01-29 22:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-29 22:25 [patch] rename members in dummy _xt_align struct Mike Frysinger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).