libnetlink: remove unused junk callback

Both rtnl_talk and rtnl_dump had a callback for handling portions
of netlink message that do not match the correct pid or seq.
But this callback was never used by any part of iproute2 so remove
it.
diff --git a/genl/ctrl.c b/genl/ctrl.c
index 38a9761..58d13be 100644
--- a/genl/ctrl.c
+++ b/genl/ctrl.c
@@ -67,7 +67,7 @@
 
 	addattr_l(nlh, 128, CTRL_ATTR_FAMILY_NAME, family, strlen(family) + 1);
 
-	if (rtnl_talk(&rth, nlh, 0, 0, nlh, NULL, NULL) < 0) {
+	if (rtnl_talk(&rth, nlh, 0, 0, nlh) < 0) {
 		fprintf(stderr, "Error talking to the kernel\n");
 		goto errout;
 	}
@@ -334,7 +334,7 @@
 			goto ctrl_done;
 		}
 
-		if (rtnl_talk(&rth, nlh, 0, 0, nlh, NULL, NULL) < 0) {
+		if (rtnl_talk(&rth, nlh, 0, 0, nlh) < 0) {
 			fprintf(stderr, "Error talking to the kernel\n");
 			goto ctrl_done;
 		}
@@ -355,7 +355,7 @@
 			goto ctrl_done;
 		}
 
-		rtnl_dump_filter(&rth, print_ctrl, stdout, NULL, NULL);
+		rtnl_dump_filter(&rth, print_ctrl, stdout);
 
         }
 
diff --git a/include/libnetlink.h b/include/libnetlink.h
index c54c7f6..a828032 100644
--- a/include/libnetlink.h
+++ b/include/libnetlink.h
@@ -32,21 +32,14 @@
 {
 	rtnl_filter_t filter;
 	void *arg1;
-	rtnl_filter_t junk;
-	void *arg2;
 };
 
 extern int rtnl_dump_filter_l(struct rtnl_handle *rth,
 			      const struct rtnl_dump_filter_arg *arg);
 extern int rtnl_dump_filter(struct rtnl_handle *rth, rtnl_filter_t filter,
-			    void *arg1,
-			    rtnl_filter_t junk,
-			    void *arg2);
-
+			    void *arg);
 extern int rtnl_talk(struct rtnl_handle *rtnl, struct nlmsghdr *n, pid_t peer,
-		     unsigned groups, struct nlmsghdr *answer,
-		     rtnl_filter_t junk,
-		     void *jarg);
+		     unsigned groups, struct nlmsghdr *answer);
 extern int rtnl_send(struct rtnl_handle *rth, const void *buf, int);
 extern int rtnl_send_check(struct rtnl_handle *rth, const void *buf, int);
 
@@ -74,8 +67,8 @@
 	(parse_rtattr((tb), (max), RTA_DATA(rta), RTA_PAYLOAD(rta)))
 
 #define parse_rtattr_nested_compat(tb, max, rta, data, len) \
-({	data = RTA_PAYLOAD(rta) >= len ? RTA_DATA(rta) : NULL; \
-	__parse_rtattr_nested_compat(tb, max, rta, len); })
+	({ data = RTA_PAYLOAD(rta) >= len ? RTA_DATA(rta) : NULL;	\
+		__parse_rtattr_nested_compat(tb, max, rta, len); })
 
 extern int rtnl_listen(struct rtnl_handle *, rtnl_filter_t handler,
 		       void *jarg);
diff --git a/ip/ipaddress.c b/ip/ipaddress.c
index 2f2cabd..4a0ffd6 100644
--- a/ip/ipaddress.c
+++ b/ip/ipaddress.c
@@ -833,7 +833,7 @@
 		exit(1);
 	}
 
-	if (rtnl_dump_filter(&rth, store_nlmsg, &linfo, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, store_nlmsg, &linfo) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
@@ -859,20 +859,14 @@
 				{
 					.filter = print_addrinfo_secondary,
 					.arg1 = stdout,
-					.junk = NULL,
-					.arg2 = NULL
 				},
 				{
 					.filter = print_addrinfo_primary,
 					.arg1 = stdout,
-					.junk = NULL,
-					.arg2 = NULL
 				},
 				{
 					.filter = NULL,
 					.arg1 = NULL,
-					.junk = NULL,
-					.arg2 = NULL
 				},
 			};
 			if (rtnl_wilddump_request(&rth, filter.family, RTM_GETADDR) < 0) {
@@ -923,7 +917,7 @@
 			exit(1);
 		}
 
-		if (rtnl_dump_filter(&rth, store_nlmsg, &ainfo, NULL, NULL) < 0) {
+		if (rtnl_dump_filter(&rth, store_nlmsg, &ainfo) < 0) {
 			fprintf(stderr, "Dump terminated\n");
 			exit(1);
 		}
@@ -1214,7 +1208,7 @@
 			  sizeof(cinfo));
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		return -2;
 
 	return 0;
diff --git a/ip/ipaddrlabel.c b/ip/ipaddrlabel.c
index a71855d..eb6a48c 100644
--- a/ip/ipaddrlabel.c
+++ b/ip/ipaddrlabel.c
@@ -114,7 +114,7 @@
 		return 1;
 	}
 
-	if (rtnl_dump_filter(&rth, print_addrlabel, stdout, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, print_addrlabel, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}
@@ -183,7 +183,7 @@
 	if (req.ifal.ifal_family == AF_UNSPEC)
 		req.ifal.ifal_family = AF_INET6;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		return 2;
 
 	return 0;
@@ -210,7 +210,7 @@
 		if (rtnl_open(&rth2, 0) < 0)
 			return -1;
 
-		if (rtnl_talk(&rth2, n, 0, 0, NULL, NULL, NULL) < 0)
+		if (rtnl_talk(&rth2, n, 0, 0, NULL) < 0)
 			return -2;
 
 		rtnl_close(&rth2);
@@ -236,7 +236,7 @@
 		return 1;
 	}
 
-	if (rtnl_dump_filter(&rth, flush_addrlabel, NULL, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, flush_addrlabel, NULL) < 0) {
 		fprintf(stderr, "Flush terminated\n");
 		return 1;
 	}
diff --git a/ip/iplink.c b/ip/iplink.c
index d41605b..6b051b6 100644
--- a/ip/iplink.c
+++ b/ip/iplink.c
@@ -482,7 +482,7 @@
 
 			req.i.ifi_index = 0;
 			addattr32(&req.n, sizeof(req), IFLA_GROUP, group);
-			if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+			if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 				exit(2);
 			return 0;
 		}
@@ -559,7 +559,7 @@
 		addattr_l(&req.n, sizeof(req), IFLA_IFNAME, name, len);
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	return 0;
diff --git a/ip/ipneigh.c b/ip/ipneigh.c
index dff9eb4..c8f745e 100644
--- a/ip/ipneigh.c
+++ b/ip/ipneigh.c
@@ -174,7 +174,7 @@
 		return -1;
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	return 0;
@@ -391,7 +391,7 @@
 				exit(1);
 			}
 			filter.flushed = 0;
-			if (rtnl_dump_filter(&rth, print_neigh, stdout, NULL, NULL) < 0) {
+			if (rtnl_dump_filter(&rth, print_neigh, stdout) < 0) {
 				fprintf(stderr, "Flush terminated\n");
 				exit(1);
 			}
@@ -423,7 +423,7 @@
 		exit(1);
 	}
 
-	if (rtnl_dump_filter(&rth, print_neigh, stdout, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, print_neigh, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
diff --git a/ip/ipntable.c b/ip/ipntable.c
index 141ad42..b00d3dc 100644
--- a/ip/ipntable.c
+++ b/ip/ipntable.c
@@ -313,7 +313,7 @@
 			  RTA_PAYLOAD(parms_rta));
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	return 0;
@@ -625,7 +625,7 @@
 		exit(1);
 	}
 
-	if (rtnl_dump_filter(&rth, print_ntable, stdout, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, print_ntable, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
diff --git a/ip/iproute.c b/ip/iproute.c
index 15b36e8..c97f979 100644
--- a/ip/iproute.c
+++ b/ip/iproute.c
@@ -1011,7 +1011,7 @@
 	if (req.r.rtm_family == AF_UNSPEC)
 		req.r.rtm_family = AF_INET;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	return 0;
@@ -1289,7 +1289,7 @@
 				exit(1);
 			}
 			filter.flushed = 0;
-			if (rtnl_dump_filter(&rth, filter_fn, stdout, NULL, NULL) < 0) {
+			if (rtnl_dump_filter(&rth, filter_fn, stdout) < 0) {
 				fprintf(stderr, "Flush terminated\n");
 				exit(1);
 			}
@@ -1332,7 +1332,7 @@
 		}
 	}
 
-	if (rtnl_dump_filter(&rth, filter_fn, stdout, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, filter_fn, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
@@ -1453,7 +1453,7 @@
 	if (req.r.rtm_family == AF_UNSPEC)
 		req.r.rtm_family = AF_INET;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n) < 0)
 		exit(2);
 
 	if (connected && !from_ok) {
@@ -1494,7 +1494,7 @@
 		req.n.nlmsg_flags = NLM_F_REQUEST;
 		req.n.nlmsg_type = RTM_GETROUTE;
 
-		if (rtnl_talk(&rth, &req.n, 0, 0, &req.n, NULL, NULL) < 0)
+		if (rtnl_talk(&rth, &req.n, 0, 0, &req.n) < 0)
 			exit(2);
 	}
 
@@ -1514,7 +1514,7 @@
 
 	ll_init_map(&rth);
 
-	ret = rtnl_talk(&rth, n, 0, 0, n, NULL, NULL);
+	ret = rtnl_talk(&rth, n, 0, 0, n);
 	if ((ret < 0) && (errno == EEXIST))
 		ret = 0;
 
diff --git a/ip/iprule.c b/ip/iprule.c
index 9318d8c..f983731 100644
--- a/ip/iprule.c
+++ b/ip/iprule.c
@@ -212,7 +212,7 @@
 		return 1;
 	}
 
-	if (rtnl_dump_filter(&rth, print_rule, stdout, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, print_rule, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}
@@ -355,7 +355,7 @@
 	if (!table_ok && cmd == RTM_NEWRULE)
 		req.r.rtm_table = RT_TABLE_MAIN;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		return 2;
 
 	return 0;
@@ -382,7 +382,7 @@
 		if (rtnl_open(&rth2, 0) < 0)
 			return -1;
 
-		if (rtnl_talk(&rth2, n, 0, 0, NULL, NULL, NULL) < 0)
+		if (rtnl_talk(&rth2, n, 0, 0, NULL) < 0)
 			return -2;
 
 		rtnl_close(&rth2);
@@ -408,7 +408,7 @@
 		return 1;
 	}
 
-	if (rtnl_dump_filter(&rth, flush_rule, NULL, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, flush_rule, NULL) < 0) {
 		fprintf(stderr, "Flush terminated\n");
 		return 1;
 	}
diff --git a/ip/link_gre.c b/ip/link_gre.c
index 62baaf4..c783203 100644
--- a/ip/link_gre.c
+++ b/ip/link_gre.c
@@ -72,7 +72,7 @@
 		req.i.ifi_family = preferred_family;
 		req.i.ifi_index = ifi->ifi_index;
 
-		if (rtnl_talk(&rth, &req.n, 0, 0, &req.n, NULL, NULL) < 0) {
+		if (rtnl_talk(&rth, &req.n, 0, 0, &req.n) < 0) {
 get_failed:
 			fprintf(stderr,
 				"Failed to get existing tunnel info.\n");
diff --git a/ip/rtmon.c b/ip/rtmon.c
index 7869b32..c1416a0 100644
--- a/ip/rtmon.c
+++ b/ip/rtmon.c
@@ -163,7 +163,7 @@
 
 	write_stamp(fp);
 
-	if (rtnl_dump_filter(&rth, dump_msg, fp, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, dump_msg, fp) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}
diff --git a/ip/xfrm_policy.c b/ip/xfrm_policy.c
index 2a14903..8e3aec5 100644
--- a/ip/xfrm_policy.c
+++ b/ip/xfrm_policy.c
@@ -393,7 +393,7 @@
 	if (req.xpinfo.sel.family == AF_UNSPEC)
 		req.xpinfo.sel.family = AF_INET;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	rtnl_close(&rth);
@@ -670,7 +670,7 @@
 			  (void *)&ctx, ctx.sctx.len);
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, res_nlbuf, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, res_nlbuf) < 0)
 		exit(2);
 
 	rtnl_close(&rth);
@@ -859,7 +859,7 @@
 				exit(1);
 			}
 
-			if (rtnl_dump_filter(&rth, xfrm_policy_keep, &xb, NULL, NULL) < 0) {
+			if (rtnl_dump_filter(&rth, xfrm_policy_keep, &xb) < 0) {
 				fprintf(stderr, "Delete-all terminated\n");
 				exit(1);
 			}
@@ -885,7 +885,7 @@
 			exit(1);
 		}
 
-		if (rtnl_dump_filter(&rth, xfrm_policy_print, stdout, NULL, NULL) < 0) {
+		if (rtnl_dump_filter(&rth, xfrm_policy_print, stdout) < 0) {
 			fprintf(stderr, "Dump terminated\n");
 			exit(1);
 		}
@@ -975,7 +975,7 @@
 	if (rtnl_open_byproto(&rth, 0, NETLINK_XFRM) < 0)
 		exit(1);
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n) < 0)
 		exit(2);
 
 	print_spdinfo(&req.n, (void*)stdout);
@@ -1027,7 +1027,7 @@
 	if (show_stats > 1)
 		fprintf(stderr, "Flush policy\n");
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	rtnl_close(&rth);
diff --git a/ip/xfrm_state.c b/ip/xfrm_state.c
index a76be47..0d98e78 100644
--- a/ip/xfrm_state.c
+++ b/ip/xfrm_state.c
@@ -544,7 +544,7 @@
 	if (req.xsinfo.family == AF_UNSPEC)
 		req.xsinfo.family = AF_INET;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	rtnl_close(&rth);
@@ -681,7 +681,7 @@
 		req.xspi.info.family = AF_INET;
 
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, res_n, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, res_n) < 0)
 		exit(2);
 
 	if (xfrm_state_print(NULL, res_n, (void*)stdout) < 0) {
@@ -871,7 +871,7 @@
 		req.xsid.family = AF_INET;
 
 	if (delete) {
-		if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+		if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 			exit(2);
 	} else {
 		char buf[NLMSG_BUF_SIZE];
@@ -879,7 +879,7 @@
 
 		memset(buf, 0, sizeof(buf));
 
-		if (rtnl_talk(&rth, &req.n, 0, 0, res_n, NULL, NULL) < 0)
+		if (rtnl_talk(&rth, &req.n, 0, 0, res_n) < 0)
 			exit(2);
 
 		if (xfrm_state_print(NULL, res_n, (void*)stdout) < 0) {
@@ -1015,7 +1015,7 @@
 				exit(1);
 			}
 
-			if (rtnl_dump_filter(&rth, xfrm_state_keep, &xb, NULL, NULL) < 0) {
+			if (rtnl_dump_filter(&rth, xfrm_state_keep, &xb) < 0) {
 				fprintf(stderr, "Delete-all terminated\n");
 				exit(1);
 			}
@@ -1042,7 +1042,7 @@
 			exit(1);
 		}
 
-		if (rtnl_dump_filter(&rth, xfrm_state_print, stdout, NULL, NULL) < 0) {
+		if (rtnl_dump_filter(&rth, xfrm_state_print, stdout) < 0) {
 			fprintf(stderr, "Dump terminated\n");
 			exit(1);
 		}
@@ -1120,7 +1120,7 @@
 	if (rtnl_open_byproto(&rth, 0, NETLINK_XFRM) < 0)
 		exit(1);
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, &req.n) < 0)
 		exit(2);
 
 	print_sadinfo(&req.n, (void*)stdout);
@@ -1174,7 +1174,7 @@
 		fprintf(stderr, "Flush state proto=%s\n",
 			strxf_xfrmproto(req.xsf.proto));
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		exit(2);
 
 	rtnl_close(&rth);
diff --git a/lib/libnetlink.c b/lib/libnetlink.c
index f7413b6..c8fc4ef 100644
--- a/lib/libnetlink.c
+++ b/lib/libnetlink.c
@@ -214,15 +214,8 @@
 
 				if (nladdr.nl_pid != 0 ||
 				    h->nlmsg_pid != rth->local.nl_pid ||
-				    h->nlmsg_seq != rth->dump) {
-					if (a->junk) {
-						err = a->junk(&nladdr, h,
-							      a->arg2);
-						if (err < 0)
-							return err;
-					}
+				    h->nlmsg_seq != rth->dump)
 					goto skip_it;
-				}
 
 				if (h->nlmsg_type == NLMSG_DONE) {
 					found_done = 1;
@@ -264,22 +257,18 @@
 
 int rtnl_dump_filter(struct rtnl_handle *rth,
 		     rtnl_filter_t filter,
-		     void *arg1,
-		     rtnl_filter_t junk,
-		     void *arg2)
+		     void *arg1)
 {
 	const struct rtnl_dump_filter_arg a[2] = {
-		{ .filter = filter, .arg1 = arg1, .junk = junk, .arg2 = arg2 },
-		{ .filter = NULL,   .arg1 = NULL, .junk = NULL, .arg2 = NULL }
+		{ .filter = filter, .arg1 = arg1, },
+		{ .filter = NULL,   .arg1 = NULL, },
 	};
 
 	return rtnl_dump_filter_l(rth, a);
 }
 
 int rtnl_talk(struct rtnl_handle *rtnl, struct nlmsghdr *n, pid_t peer,
-	      unsigned groups, struct nlmsghdr *answer,
-	      rtnl_filter_t junk,
-	      void *jarg)
+	      unsigned groups, struct nlmsghdr *answer)
 {
 	int status;
 	unsigned seq;
@@ -338,11 +327,10 @@
 			exit(1);
 		}
 		for (h = (struct nlmsghdr*)buf; status >= sizeof(*h); ) {
-			int err;
 			int len = h->nlmsg_len;
 			int l = len - sizeof(*h);
 
-			if (l<0 || len>status) {
+			if (l < 0 || len>status) {
 				if (msg.msg_flags & MSG_TRUNC) {
 					fprintf(stderr, "Truncated message\n");
 					return -1;
@@ -354,11 +342,6 @@
 			if (nladdr.nl_pid != peer ||
 			    h->nlmsg_pid != rtnl->local.nl_pid ||
 			    h->nlmsg_seq != seq) {
-				if (junk) {
-					err = junk(&nladdr, h, jarg);
-					if (err < 0)
-						return err;
-				}
 				/* Don't forget to skip that message. */
 				status -= NLMSG_ALIGN(len);
 				h = (struct nlmsghdr*)((char*)h + NLMSG_ALIGN(len));
diff --git a/lib/ll_map.c b/lib/ll_map.c
index d3cde22..1ca781e 100644
--- a/lib/ll_map.c
+++ b/lib/ll_map.c
@@ -204,7 +204,7 @@
 		exit(1);
 	}
 
-	if (rtnl_dump_filter(rth, ll_remember_index, NULL, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(rth, ll_remember_index, NULL) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
diff --git a/misc/ifstat.c b/misc/ifstat.c
index 7d33f5e..e7fbaa8 100644
--- a/misc/ifstat.c
+++ b/misc/ifstat.c
@@ -128,7 +128,7 @@
 		exit(1);
 	}
 
-	if (rtnl_dump_filter(&rth, get_nlmsg, NULL, NULL, NULL) < 0) {
+	if (rtnl_dump_filter(&rth, get_nlmsg, NULL) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		exit(1);
 	}
diff --git a/tc/m_action.c b/tc/m_action.c
index 6464b2e..1fe2431 100644
--- a/tc/m_action.c
+++ b/tc/m_action.c
@@ -451,7 +451,7 @@
 	if (cmd == RTM_GETACTION)
 		ans = &req.n;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, ans, NULL, NULL) < 0) {
+	if (rtnl_talk(&rth, &req.n, 0, 0, ans) < 0) {
 		fprintf(stderr, "We have an error talking to the kernel\n");
 		return 1;
 	}
@@ -496,7 +496,7 @@
 	}
 	tail->rta_len = (void *) NLMSG_TAIL(&req.n) - (void *) tail;
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0) {
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0) {
 		fprintf(stderr, "We have an error talking to the kernel\n");
 		ret = -1;
 	}
@@ -558,7 +558,7 @@
 			perror("Cannot send dump request");
 			return 1;
 		}
-		ret = rtnl_dump_filter(&rth, print_action, stdout, NULL, NULL);
+		ret = rtnl_dump_filter(&rth, print_action, stdout);
 	}
 
 	if (event == RTM_DELACTION) {
@@ -566,7 +566,7 @@
 		req.n.nlmsg_type = RTM_DELACTION;
 		req.n.nlmsg_flags |= NLM_F_ROOT;
 		req.n.nlmsg_flags |= NLM_F_REQUEST;
-		if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0) {
+		if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0) {
 			fprintf(stderr, "We have an error flushing\n");
 			return 1;
 		}
diff --git a/tc/tc_class.c b/tc/tc_class.c
index 9d4eea5..3a1a0ac 100644
--- a/tc/tc_class.c
+++ b/tc/tc_class.c
@@ -138,7 +138,7 @@
 		}
 	}
 
-	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		return 2;
 
 	return 0;
@@ -298,7 +298,7 @@
 		return 1;
 	}
 
- 	if (rtnl_dump_filter(&rth, print_class, stdout, NULL, NULL) < 0) {
+ 	if (rtnl_dump_filter(&rth, print_class, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}
diff --git a/tc/tc_filter.c b/tc/tc_filter.c
index 4e55812..d4b0b67 100644
--- a/tc/tc_filter.c
+++ b/tc/tc_filter.c
@@ -167,7 +167,7 @@
 		}
 	}
 
- 	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0) {
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0) {
 		fprintf(stderr, "We have an error talking to the kernel\n");
 		return 2;
 	}
@@ -341,7 +341,7 @@
 		return 1;
 	}
 
- 	if (rtnl_dump_filter(&rth, print_filter, stdout, NULL, NULL) < 0) {
+ 	if (rtnl_dump_filter(&rth, print_filter, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}
diff --git a/tc/tc_qdisc.c b/tc/tc_qdisc.c
index c7f2988..0822e63 100644
--- a/tc/tc_qdisc.c
+++ b/tc/tc_qdisc.c
@@ -186,7 +186,7 @@
 		req.t.tcm_ifindex = idx;
 	}
 
- 	if (rtnl_talk(&rth, &req.n, 0, 0, NULL, NULL, NULL) < 0)
+	if (rtnl_talk(&rth, &req.n, 0, 0, NULL) < 0)
 		return 2;
 
 	return 0;
@@ -323,7 +323,7 @@
 		return 1;
 	}
 
- 	if (rtnl_dump_filter(&rth, print_qdisc, stdout, NULL, NULL) < 0) {
+ 	if (rtnl_dump_filter(&rth, print_qdisc, stdout) < 0) {
 		fprintf(stderr, "Dump terminated\n");
 		return 1;
 	}