Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1161121AbVLWWyx (ORCPT ); Fri, 23 Dec 2005 17:54:53 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1161102AbVLWWyN (ORCPT ); Fri, 23 Dec 2005 17:54:13 -0500 Received: from mail.kroah.org ([69.55.234.183]:47055 "EHLO perch.kroah.org") by vger.kernel.org with ESMTP id S1161100AbVLWWtY (ORCPT ); Fri, 23 Dec 2005 17:49:24 -0500 Date: Fri, 23 Dec 2005 14:47:46 -0800 From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , torvalds@osdl.org, akpm@osdl.org, alan@lxorguk.ukuu.org.uk, Harald Welte , Netfilter Development Mailinglist , Pablo Neira Ayuso , kaber@trash.net, ole@ans.pl Subject: [patch 03/19] [NETFILTER]: Fix CTA_PROTO_NUM attribute size in ctnetlink Message-ID: <20051223224746.GC19057@kroah.com> References: <20051223221200.342826000@press.kroah.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="fix-cta_proto_num-attribute-size-in-ctnetlink.patch" In-Reply-To: <20051223224712.GA18975@kroah.com> User-Agent: Mutt/1.5.11 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1435 Lines: 43 -stable review patch. If anyone has any objections, please let us know. ------------------ From: Krzysztof Oledzki CTA_PROTO_NUM is a u_int8_t. Based on oryginal patch by Patrick McHardy Signed-off-by: Krzysztof Piotr Oledzki Signed-off-by: Greg Kroah-Hartman --- net/ipv4/netfilter/ip_conntrack_netlink.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- linux-2.6.14.4.orig/net/ipv4/netfilter/ip_conntrack_netlink.c +++ linux-2.6.14.4/net/ipv4/netfilter/ip_conntrack_netlink.c @@ -506,7 +506,7 @@ nfattr_failure: } static const int cta_min_proto[CTA_PROTO_MAX] = { - [CTA_PROTO_NUM-1] = sizeof(u_int16_t), + [CTA_PROTO_NUM-1] = sizeof(u_int8_t), [CTA_PROTO_SRC_PORT-1] = sizeof(u_int16_t), [CTA_PROTO_DST_PORT-1] = sizeof(u_int16_t), [CTA_PROTO_ICMP_TYPE-1] = sizeof(u_int8_t), @@ -532,7 +532,7 @@ ctnetlink_parse_tuple_proto(struct nfatt if (!tb[CTA_PROTO_NUM-1]) return -EINVAL; - tuple->dst.protonum = *(u_int16_t *)NFA_DATA(tb[CTA_PROTO_NUM-1]); + tuple->dst.protonum = *(u_int8_t *)NFA_DATA(tb[CTA_PROTO_NUM-1]); proto = ip_conntrack_proto_find_get(tuple->dst.protonum); -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/