[netfilter-cvslog] r4182 - trunk/libnfnetlink_log/src

laforge at netfilter.org laforge at netfilter.org
Sat Jul 30 11:32:01 CEST 2005


Author: laforge at netfilter.org
Date: 2005-07-30 11:32:00 +0200 (Sat, 30 Jul 2005)
New Revision: 4182

Modified:
   trunk/libnfnetlink_log/src/libnfnetlink_log.c
Log:
don't create new field for 'pf' if we already have one...


Modified: trunk/libnfnetlink_log/src/libnfnetlink_log.c
===================================================================
--- trunk/libnfnetlink_log/src/libnfnetlink_log.c	2005-07-30 09:31:34 UTC (rev 4181)
+++ trunk/libnfnetlink_log/src/libnfnetlink_log.c	2005-07-30 09:32:00 UTC (rev 4182)
@@ -55,7 +55,7 @@
 /* build a NFULNL_MSG_CONFIG message */
 static int
 __build_send_cfg_msg(struct nfulnl_handle *h, u_int8_t command,
-		     u_int16_t queuenum, u_int16_t pf)
+		     u_int16_t queuenum, u_int8_t pf)
 {
 	char buf[NLMSG_LENGTH(sizeof(struct nlmsghdr))
 		+NLMSG_LENGTH(sizeof(struct nfgenmsg))
@@ -63,11 +63,10 @@
 	struct nfulnl_msg_config_cmd cmd;
 	struct nlmsghdr *nmh = (struct nlmsghdr *) buf;
 
-	nfnl_fill_hdr(&h->nfnlh, nmh, 0, AF_UNSPEC, queuenum,
+	nfnl_fill_hdr(&h->nfnlh, nmh, 0, pf, queuenum,
 		      NFULNL_MSG_CONFIG, NLM_F_REQUEST|NLM_F_ACK);
 
 	cmd.command = command;
-	cmd.pf = htons(pf);
 	nfnl_addattr_l(nmh, sizeof(buf), NFULA_CFG_CMD, &cmd, sizeof(cmd));
 
 	return nfnl_send(&h->nfnlh, nmh);
@@ -124,4 +123,3 @@
 
 	return nfnl_send(&gh->h->nfnlh, nmh);
 }
-




More information about the netfilter-cvslog mailing list