From: Patrick McHardy <kaber@trash.net>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Simon Horman <horms@verge.net.au>,
dada1@cosmosbay.com, davem@davemloft.net, netdev@vger.kernel.org,
netfilter-devel@lists.netfilter.org
Subject: Re: [PATCH, take2] netfilter : struct xt_table_info diet
Date: Tue, 20 Nov 2007 08:50:15 +0100 [thread overview]
Message-ID: <474291B7.6060602@trash.net> (raw)
In-Reply-To: <E1IuN87-0003r5-00@gondolin.me.apana.org.au>
Herbert Xu wrote:
> Simon Horman <horms@verge.net.au> wrote:
>
>> @@ -269,9 +269,12 @@ struct xt_table_info
>> unsigned int underflow[NF_INET_NUMHOOKS];
>>
>> /* ipt_entry tables: one per CPU */
>> - char *entries[NR_CPUS];
>> + /* Note : this field MUST be the last one, see XT_TABLE_INFO_SZ */
>> + char *entries[1];
>>
>
> Just do
>
> char *entries[];
>
> Not only is it ISO C99, but the compiler will die if it's not at
> the end.
>
> Actually I haven't read the rest of the patch, so scratch this
> comment if you really need to have one entry there for some reason :)
>
I thought this too, but its needed for the bootstrap tables, which are
declared on the stack :)
next prev parent reply other threads:[~2007-11-20 7:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-14 21:50 [PATCH, take2] netfilter : struct xt_table_info diet Eric Dumazet
2007-11-15 12:41 ` Patrick McHardy
2007-11-15 15:45 ` Eric Dumazet
2007-11-15 15:58 ` Patrick McHardy
2007-11-20 6:32 ` Simon Horman
2007-11-20 7:02 ` Herbert Xu
2007-11-20 7:50 ` Patrick McHardy [this message]
2007-11-20 7:54 ` Patrick McHardy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=474291B7.6060602@trash.net \
--to=kaber@trash.net \
--cc=dada1@cosmosbay.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=horms@verge.net.au \
--cc=netdev@vger.kernel.org \
--cc=netfilter-devel@lists.netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).