diff mbox

[5/5] ipset: data callback does not need to be part of cb_ctl[]

Message ID 20140908143053.16930.68662.stgit@jonathan.eitzenberger.org
State Not Applicable
Delegated to: Jozsef Kadlecsik
Headers show

Commit Message

holger@eitzenberger.org Sept. 8, 2014, 2:30 p.m. UTC
Because the data callback is passed explicitely to mnl_cb_run2()
there is no need to add it to cb_ctl[].  For nlmsg_types
>= NLMSG_MIN_TYPE the data callback is used explicitely.

Signed-off-by: Holger Eitzenberger <holger@eitzenberger.org>
---
 lib/session.c |    1 -
 1 file changed, 1 deletion(-)


--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

holger@eitzenberger.org Sept. 8, 2014, 3:26 p.m. UTC | #1
Hi Jozsef,

> Because the data callback is passed explicitely to mnl_cb_run2()
> there is no need to add it to cb_ctl[].  For nlmsg_types
> >= NLMSG_MIN_TYPE the data callback is used explicitely.

Just noticed that there is a side effect to this one.  So please
just ignore this patch for now.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/lib/session.c b/lib/session.c
index 8d79a96..807f0d3 100644
--- a/lib/session.c
+++ b/lib/session.c
@@ -1868,7 +1868,6 @@  static mnl_cb_t cb_ctl[] = {
 	[NLMSG_ERROR] = callback_error,
 	[NLMSG_DONE]  = callback_done,
 	[NLMSG_OVERRUN] = callback_noop,
-	[NLMSG_MIN_TYPE] = callback_data,
 };
 
 static inline struct ipset_handle *