[prev in list] [next in list] [prev in thread] [next in thread] 

List:       netfilter
Subject:    Re: [PATCH] ip_tables.h: Add the const qualifier.
From:       Jan Engelhardt <jengelh () medozas ! de>
Date:       2011-09-28 12:16:45
Message-ID: alpine.LNX.2.01.1109281413350.32661 () frira ! zrqbmnf ! qr
[Download RAW message or body]

On Wednesday 2011-09-28 09:32, Il Han wrote:

>We need to add the const qualifier before the struct specifier,
>because its value will not be changed.
>Then, the following warning would be removed.
>
>net/ipv4/netfilter/ip_tables.c:183: warning: passing argument 1 of 
>'ipt_get_target' discards qualifiers from pointer target type

gcc-4.6.1_20110801 does not output any such warning - which also 
seems to be correct, since line 183 reads:

	return ipt_get_target((struct ipt_entry *)e);

So in ipt_get_target_c, we already do away with the const qualifier 
before calling ipt_get_target.
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic