lib: fix compile warnings from set-never-used

The if_dump code had empty loop, that caused set-never-used warning.
diff --git a/lib/if.c b/lib/if.c
index d14cfb9..41115b0 100644
--- a/lib/if.c
+++ b/lib/if.c
@@ -426,9 +426,6 @@
 static void
 if_dump (const struct interface *ifp)
 {
-  struct listnode *node;
-  struct connected *c;
-
   zlog_info ("Interface %s index %d metric %d mtu %d "
 #ifdef HAVE_IPV6
              "mtu6 %d "
@@ -439,9 +436,6 @@
 	     ifp->mtu6,
 #endif /* HAVE_IPV6 */
 	     if_flag_dump (ifp->flags));
-  
-  for (ALL_LIST_ELEMENTS_RO (ifp->connected, node, c))
-    ;
 }
 
 /* Interface printing for all interface. */