[netfilter-cvslog] r4361 - trunk/libnfnetlink_conntrack/src
pablo at netfilter.org
pablo at netfilter.org
Mon Oct 17 01:23:38 CEST 2005
Author: pablo at netfilter.org
Date: 2005-10-17 01:23:38 +0200 (Mon, 17 Oct 2005)
New Revision: 4361
Modified:
trunk/libnfnetlink_conntrack/src/libnetfilter_conntrack.c
Log:
Fix the calculation of the mininum size of a message. This fix the deficit complain of nfnl_parse_attr.
Modified: trunk/libnfnetlink_conntrack/src/libnetfilter_conntrack.c
===================================================================
--- trunk/libnfnetlink_conntrack/src/libnetfilter_conntrack.c 2005-10-16 21:46:30 UTC (rev 4360)
+++ trunk/libnfnetlink_conntrack/src/libnetfilter_conntrack.c 2005-10-16 23:23:38 UTC (rev 4361)
@@ -402,7 +402,7 @@
struct nlmsghdr *nlh, void *arg)
{
struct nfgenmsg *nfmsg;
- int min_len = sizeof(struct nfgenmsg);;
+ int min_len = sizeof(struct nfgenmsg) + sizeof(struct nlmsghdr);
struct nfattr *attr = NFM_NFA(NLMSG_DATA(nlh));
int attrlen = nlh->nlmsg_len - NLMSG_ALIGN(min_len);
struct nfct_conntrack ct;
@@ -571,7 +571,7 @@
{
struct nfgenmsg *nfmsg;
struct nfct_handle *cth = arg;
- int min_len = sizeof(struct nfgenmsg);
+ int min_len = sizeof(struct nfgenmsg) + sizeof(struct nlmsghdr);
struct nfattr *attr = NFM_NFA(NLMSG_DATA(nlh));
int attrlen = nlh->nlmsg_len - NLMSG_ALIGN(min_len);
struct nfct_expect exp;
More information about the netfilter-cvslog
mailing list