[libmnl,3/3] examples: reduce LOCs during neigh attributes validation
diff mbox series

Message ID 20180521171248.avqmgsuytrfxm6cu@nevthink
State Accepted
Delegated to: Pablo Neira
Headers show
Series
  • examples: rtnl neigh dump cleanups
Related show

Commit Message

Laura Garcia May 21, 2018, 5:12 p.m. UTC
This patch avoids some LOCs duplication.

Signed-off-by: Laura Garcia Liebana <nevola@gmail.com>
---
 examples/rtnl/rtnl-neigh-dump.c | 5 -----
 1 file changed, 5 deletions(-)

Patch
diff mbox series

diff --git a/examples/rtnl/rtnl-neigh-dump.c b/examples/rtnl/rtnl-neigh-dump.c
index 54d87e5..f4d5000 100644
--- a/examples/rtnl/rtnl-neigh-dump.c
+++ b/examples/rtnl/rtnl-neigh-dump.c
@@ -22,11 +22,6 @@  static int data_attr_cb(const struct nlattr *attr, void *data)
 
 	switch(type) {
 	case NDA_DST:
-		if (mnl_attr_validate(attr, MNL_TYPE_BINARY) < 0) {
-			perror("mnl_attr_validate");
-			return MNL_CB_ERROR;
-		}
-		break;
 	case NDA_LLADDR:
 		if (mnl_attr_validate(attr, MNL_TYPE_BINARY) < 0) {
 			perror("mnl_attr_validate");