diff --git a/bgpd/bgp_nexthop.c b/bgpd/bgp_nexthop.c
index 0cde665..de303e3 100644
--- a/bgpd/bgp_nexthop.c
+++ b/bgpd/bgp_nexthop.c
@@ -146,7 +146,7 @@
 }
 
 static int
-bgp_nexthop_cache_changed (struct bgp_nexthop_cache *bnc1,
+bgp_nexthop_cache_different (struct bgp_nexthop_cache *bnc1,
 			   struct bgp_nexthop_cache *bnc2)
 {
   int i;
@@ -171,7 +171,7 @@
 
 /* If nexthop exists on connected network return 1. */
 int
-bgp_nexthop_check_ebgp (afi_t afi, struct attr *attr)
+bgp_nexthop_onlink (afi_t afi, struct attr *attr)
 {
   struct bgp_node *rn;
 
@@ -256,12 +256,11 @@
       bnc = zlookup_query_ipv6 (&attr->extra->mp_nexthop_global);
       if (bnc)
 	{
-	  struct bgp_table *old;
-	  struct bgp_node *oldrn;
-	  struct bgp_nexthop_cache *oldbnc;
-
 	  if (changed)
 	    {
+	      struct bgp_table *old;
+	      struct bgp_node *oldrn;
+
 	      if (bgp_nexthop_cache_table[AFI_IP6] == cache1_table[AFI_IP6])
 		old = cache2_table[AFI_IP6];
 	      else
@@ -270,9 +269,9 @@
 	      oldrn = bgp_node_lookup (old, &p);
 	      if (oldrn)
 		{
-		  oldbnc = oldrn->info;
+		  struct bgp_nexthop_cache *oldbnc = oldrn->info;
 
-		  bnc->changed = bgp_nexthop_cache_changed (bnc, oldbnc);
+		  bnc->changed = bgp_nexthop_cache_different (bnc, oldbnc);
 
 		  if (bnc->metric != oldbnc->metric)
 		    bnc->metricchanged = 1;
@@ -282,7 +281,6 @@
       else
 	{
 	  bnc = bnc_new ();
-	  bnc->valid = 0;
 	}
       rn->info = bnc;
     }
@@ -345,12 +343,11 @@
       bnc = zlookup_query (addr);
       if (bnc)
 	{
-	  struct bgp_table *old;
-	  struct bgp_node *oldrn;
-	  struct bgp_nexthop_cache *oldbnc;
-
 	  if (changed)
 	    {
+	      struct bgp_table *old;
+	      struct bgp_node *oldrn;
+
 	      if (bgp_nexthop_cache_table[AFI_IP] == cache1_table[AFI_IP])
 		old = cache2_table[AFI_IP];
 	      else
@@ -359,9 +356,9 @@
 	      oldrn = bgp_node_lookup (old, &p);
 	      if (oldrn)
 		{
-		  oldbnc = oldrn->info;
+		  struct bgp_nexthop_cache *oldbnc = oldrn->info;
 
-		  bnc->changed = bgp_nexthop_cache_changed (bnc, oldbnc);
+		  bnc->changed = bgp_nexthop_cache_different (bnc, oldbnc);
 
 		  if (bnc->metric != oldbnc->metric)
 		    bnc->metricchanged = 1;
@@ -371,7 +368,6 @@
       else
 	{
 	  bnc = bnc_new ();
-	  bnc->valid = 0;
 	}
       rn->info = bnc;
     }
@@ -458,7 +454,7 @@
 	      metricchanged = 0;
 
 	      if (peer_sort (bi->peer) == BGP_PEER_EBGP && bi->peer->ttl == 1)
-		valid = bgp_nexthop_check_ebgp (afi, bi->attr);
+		valid = bgp_nexthop_onlink (afi, bi->attr);
 	      else
 		valid = bgp_nexthop_lookup (afi, bi->peer, bi,
 					    &changed, &metricchanged);
