diff --git a/ospf6d/ChangeLog b/ospf6d/ChangeLog
index 43225bf..e802e32 100644
--- a/ospf6d/ChangeLog
+++ b/ospf6d/ChangeLog
@@ -1,5 +1,10 @@
 2004-08-19  Yasuhiro Ohara  <yasu@sfc.wide.ad.jp>
 
+	* ospf6_asbr.c: Bug in ASBR check fixed.
+	* ospf6d.h: version 0.9.7k
+
+2004-08-19  Yasuhiro Ohara  <yasu@sfc.wide.ad.jp>
+
 	* ospf6_asbr.c: Bug in AS-External Origination fixed.
 	* ospf6d.h: version 0.9.7j
 
diff --git a/ospf6d/ospf6_abr.c b/ospf6d/ospf6_abr.c
index e9dc238..2d4b10f 100644
--- a/ospf6d/ospf6_abr.c
+++ b/ospf6d/ospf6_abr.c
@@ -499,6 +499,7 @@
   u_int8_t prefix_options = 0;
   u_int32_t cost = 0;
   int i;
+  char buf[64];
 
   if (IS_OSPF6_DEBUG_ABR)
     zlog_info ("Examin %s in area %s", lsa->name, oa->name);
@@ -511,6 +512,7 @@
       prefix.family = AF_INET6;
       prefix.prefixlen = prefix_lsa->prefix.prefix_length;
       ospf6_prefix_in6_addr (&prefix.u.prefix6, &prefix_lsa->prefix);
+      prefix2str (&prefix, buf, sizeof (buf));
       table = oa->ospf6->route_table;
       type = OSPF6_DEST_TYPE_NETWORK;
       prefix_options = prefix_lsa->prefix.prefix_options;
@@ -522,6 +524,7 @@
       router_lsa = (struct ospf6_inter_router_lsa *)
         OSPF6_LSA_HEADER_END (lsa->header);
       ospf6_linkstate_prefix (router_lsa->router_id, htonl (0), &prefix);
+      inet_ntop (AF_INET, &router_lsa->router_id, buf, sizeof (buf));
       table = oa->ospf6->brouter_table;
       type = OSPF6_DEST_TYPE_ROUTER;
       options[0] = router_lsa->options[0];
@@ -532,15 +535,18 @@
   else
     assert (0);
 
-  for (route = ospf6_route_lookup (&prefix, table);
-       route && ospf6_route_is_prefix (&prefix, route);
-       route = ospf6_route_next (route))
+  /* Find existing route */
+  route = ospf6_route_lookup (&prefix, table);
+  if (route)
+    ospf6_route_lock (route);
+  while (route && ospf6_route_is_prefix (&prefix, route))
     {
       if (route->path.area_id == oa->area_id &&
           route->path.origin.type == lsa->header->type &&
           route->path.origin.id == lsa->header->id &&
           route->path.origin.adv_router == lsa->header->adv_router)
         old = route;
+      route = ospf6_route_next (route);
     }
 
   /* (1) if cost == LSInfinity or if the LSA is MaxAge */
@@ -589,6 +595,7 @@
   ospf6_linkstate_prefix (lsa->header->adv_router, htonl (0), &abr_prefix);
   abr_entry = ospf6_route_lookup (&abr_prefix, oa->ospf6->brouter_table);
   if (abr_entry == NULL || abr_entry->path.area_id != oa->area_id ||
+      CHECK_FLAG (abr_entry->flag, OSPF6_ROUTE_REMOVE) ||
       ! CHECK_FLAG (abr_entry->path.router_bits, OSPF6_ROUTER_BIT_B))
     {
       if (IS_OSPF6_DEBUG_ABR)
@@ -602,7 +609,7 @@
      in the routing table. Always install the path by substituting
      old route (if any). */
   if (old)
-    route = old;
+    route = ospf6_route_copy (old);
   else
     route = ospf6_route_create ();
 
@@ -622,10 +629,45 @@
     route->nexthop[i] = abr_entry->nexthop[i];
 
   if (IS_OSPF6_DEBUG_ABR)
-    zlog_info ("Install route");
+    zlog_info ("Install route: %s", buf);
   ospf6_route_add (route, table);
 }
 
+void
+ospf6_abr_examin_brouter (u_int32_t router_id)
+{
+  struct ospf6_lsa *lsa;
+  struct ospf6_area *oa;
+  listnode node;
+  u_int16_t type;
+
+  if (IS_OSPF6_DEBUG_ABR)
+    {
+      char buf[16];
+      inet_ntop (AF_INET, &router_id, buf, sizeof (buf));
+      zlog_info ("Router entry of %s changed", buf);
+      zlog_info ("Examin summary LSAs originated by the router");
+    }
+
+  type = htons (OSPF6_LSTYPE_INTER_ROUTER);
+  for (node = listhead (ospf6->area_list); node; nextnode (node))
+    {
+      oa = OSPF6_AREA (getdata (node));
+      for (lsa = ospf6_lsdb_type_router_head (type, router_id, oa->lsdb); lsa;
+           lsa = ospf6_lsdb_type_router_next (type, router_id, lsa))
+        ospf6_abr_examin_summary (lsa, oa);
+    }
+
+  type = htons (OSPF6_LSTYPE_INTER_PREFIX);
+  for (node = listhead (ospf6->area_list); node; nextnode (node))
+    {
+      oa = OSPF6_AREA (getdata (node));
+      for (lsa = ospf6_lsdb_type_router_head (type, router_id, oa->lsdb); lsa;
+           lsa = ospf6_lsdb_type_router_next (type, router_id, lsa))
+        ospf6_abr_examin_summary (lsa, oa);
+    }
+}
+
 
 /* Display functions */
 int
diff --git a/ospf6d/ospf6_abr.h b/ospf6d/ospf6_abr.h
index 3257c73..ce3c19a 100644
--- a/ospf6d/ospf6_abr.h
+++ b/ospf6d/ospf6_abr.h
@@ -61,6 +61,7 @@
                                           struct ospf6_area *area);
 void ospf6_abr_originate_summary (struct ospf6_route *route);
 void ospf6_abr_examin_summary (struct ospf6_lsa *lsa, struct ospf6_area *oa);
+void ospf6_abr_examin_brouter (u_int32_t router_id);
 
 int config_write_ospf6_debug_abr (struct vty *vty);
 void install_element_ospf6_debug_abr ();
diff --git a/ospf6d/ospf6_area.c b/ospf6d/ospf6_area.c
index fc2103c..312d88f 100644
--- a/ospf6d/ospf6_area.c
+++ b/ospf6d/ospf6_area.c
@@ -68,6 +68,7 @@
 
     case OSPF6_LSTYPE_INTER_PREFIX:
     case OSPF6_LSTYPE_INTER_ROUTER:
+      ospf6_abr_examin_summary (lsa, (struct ospf6_area *) lsa->lsdb->data);
       break;
 
     default:
@@ -94,6 +95,7 @@
 
     case OSPF6_LSTYPE_INTER_PREFIX:
     case OSPF6_LSTYPE_INTER_ROUTER:
+      ospf6_abr_examin_summary (lsa, (struct ospf6_area *) lsa->lsdb->data);
       break;
 
     default:
diff --git a/ospf6d/ospf6_asbr.c b/ospf6d/ospf6_asbr.c
index 7884a6b..3352465 100644
--- a/ospf6d/ospf6_asbr.c
+++ b/ospf6d/ospf6_asbr.c
@@ -192,11 +192,8 @@
       return;
     }
 
-  asbr_id.family = AF_INET;
-  asbr_id.prefixlen = 32;
-  asbr_id.u.prefix4.s_addr = lsa->header->adv_router;
+  ospf6_linkstate_prefix (lsa->header->adv_router, htonl (0), &asbr_id);
   asbr_entry = ospf6_route_lookup (&asbr_id, ospf6->brouter_table);
-
   if (asbr_entry == NULL)
     {
       if (IS_OSPF6_DEBUG_ASBR)
diff --git a/ospf6d/ospf6_flood.c b/ospf6d/ospf6_flood.c
index 0511202..660e636 100644
--- a/ospf6d/ospf6_flood.c
+++ b/ospf6d/ospf6_flood.c
@@ -220,7 +220,7 @@
     }
 
   gettimeofday (&now, (struct timezone *) NULL);
-  if (ospf6_lsa_age_current (lsa) != MAXAGE)
+  if (! OSPF6_LSA_IS_MAXAGE (lsa))
     lsa->expire = thread_add_timer (master, ospf6_lsa_expire, lsa,
                                     MAXAGE + lsa->birth.tv_sec - now.tv_sec);
   else
@@ -843,11 +843,17 @@
             }
         }
 
+      gettimeofday (&new->received, (struct timezone *) NULL);
+
       if (IS_OSPF6_DEBUG_LSA (RECV))
         zlog_info ("Flood, Install, Possibly acknowledge the received LSA");
 
       /* (b) immediately flood and (c) remove from all retrans-list */
-      ospf6_flood (from, new);
+      /* Prevent self-originated LSA to be flooded. this is to make
+      reoriginated instance of the LSA not to be rejected by other routers
+      due to MinLSArrival. */
+      if (new->header->adv_router != from->ospf6_if->area->ospf6->router_id)
+        ospf6_flood (from, new);
 
       /* (c) Remove the current database copy from all neighbors' Link
              state retransmission lists. */
diff --git a/ospf6d/ospf6_intra.c b/ospf6d/ospf6_intra.c
index 74a8964..8383fd9 100644
--- a/ospf6d/ospf6_intra.c
+++ b/ospf6d/ospf6_intra.c
@@ -1036,6 +1036,9 @@
   char *start, *current, *end;
   char buf[64];
 
+  if (OSPF6_LSA_IS_MAXAGE (lsa))
+    return;
+
   if (IS_OSPF6_DEBUG_ROUTE (INTRA))
     zlog_info ("%s found", lsa->name);
 
@@ -1081,10 +1084,12 @@
         break;
 
       route = ospf6_route_create ();
-      route->prefix.prefixlen = op->prefix_length;
+
+      memset (&route->prefix, 0, sizeof (struct prefix));
       route->prefix.family = AF_INET6;
-      memcpy (&route->prefix.u.prefix6, OSPF6_PREFIX_BODY (op),
-              OSPF6_PREFIX_SPACE (op->prefix_length));
+      route->prefix.prefixlen = op->prefix_length;
+      ospf6_prefix_in6_addr (&route->prefix.u.prefix6, op);
+
       route->type = OSPF6_DEST_TYPE_NETWORK;
       route->path.origin.type = lsa->header->type;
       route->path.origin.id = lsa->header->id;
@@ -1147,6 +1152,7 @@
         break;
       prefix_num--;
 
+      memset (&prefix, 0, sizeof (struct prefix));
       prefix.family = AF_INET6;
       prefix.prefixlen = op->prefix_length;
       ospf6_prefix_in6_addr (&prefix.u.prefix6, op);
@@ -1246,6 +1252,7 @@
   struct ospf6_route *lsentry, *copy;
   void (*hook_add) (struct ospf6_route *) = NULL;
   void (*hook_remove) (struct ospf6_route *) = NULL;
+  char buf[16];
 
   if (IS_OSPF6_DEBUG_ROUTE (INTRA))
     zlog_info ("Border-router calculation for area %s", oa->name);
@@ -1277,9 +1284,15 @@
 
       copy = ospf6_route_copy (lsentry);
       copy->type = OSPF6_DEST_TYPE_ROUTER;
-      copy->prefix.family = AF_INET;
-      copy->prefix.prefixlen = 32;
+      copy->path.area_id = oa->area_id;
       ospf6_route_add (copy, oa->ospf6->brouter_table);
+
+      if (IS_OSPF6_DEBUG_ROUTE (INTRA))
+        {
+          inet_ntop (AF_INET, &ADV_ROUTER_IN_PREFIX (&copy->prefix),
+                     buf, sizeof (buf));
+          zlog_info ("Re-install router entry %s", buf);
+        }
     }
 
   oa->ospf6->brouter_table->hook_add = hook_add;
@@ -1303,6 +1316,12 @@
       else if (CHECK_FLAG (lsentry->flag, OSPF6_ROUTE_ADD) ||
                CHECK_FLAG (lsentry->flag, OSPF6_ROUTE_CHANGE))
         {
+          if (IS_OSPF6_DEBUG_ROUTE (INTRA))
+            {
+              inet_ntop (AF_INET, &ADV_ROUTER_IN_PREFIX (&lsentry->prefix),
+                         buf, sizeof (buf));
+              zlog_info ("Call hook for router entry %s", buf);
+            }
           if (hook_add)
             (*hook_add) (lsentry);
         }
diff --git a/ospf6d/ospf6_lsa.c b/ospf6d/ospf6_lsa.c
index 8eea002..6c8341f 100644
--- a/ospf6d/ospf6_lsa.c
+++ b/ospf6d/ospf6_lsa.c
@@ -497,8 +497,9 @@
   assert (copy->lock == 0);
 
   copy->birth = lsa->birth;
-  copy->installed = lsa->installed;
   copy->originated = lsa->originated;
+  copy->received = lsa->received;
+  copy->installed = lsa->installed;
   copy->lsdb = lsa->lsdb;
 
   return copy;
diff --git a/ospf6d/ospf6_lsa.h b/ospf6d/ospf6_lsa.h
index 961f11e..be28449 100644
--- a/ospf6d/ospf6_lsa.h
+++ b/ospf6d/ospf6_lsa.h
@@ -113,8 +113,9 @@
   unsigned char     flag;           /* special meaning (e.g. floodback) */
 
   struct timeval    birth;          /* tv_sec when LS age 0 */
-  struct timeval    installed;      /* used by MinLSArrival check */
   struct timeval    originated;     /* used by MinLSInterval check */
+  struct timeval    received;       /* used by MinLSArrival check */
+  struct timeval    installed;
 
   struct thread    *expire;
   struct thread    *refresh;        /* For self-originated LSA */
diff --git a/ospf6d/ospf6_lsdb.c b/ospf6d/ospf6_lsdb.c
index 247238b..6cd633f 100644
--- a/ospf6d/ospf6_lsdb.c
+++ b/ospf6d/ospf6_lsdb.c
@@ -174,6 +174,11 @@
                   (*lsdb->hook_remove) (lsa);
                 }
             }
+          else if (OSPF6_LSA_IS_MAXAGE (old))
+            {
+              if (lsdb->hook_add)
+                (*lsdb->hook_add) (lsa);
+            }
           else
             {
               if (lsdb->hook_remove)
diff --git a/ospf6d/ospf6_message.c b/ospf6d/ospf6_message.c
index 7e022da..276c847 100644
--- a/ospf6d/ospf6_message.c
+++ b/ospf6d/ospf6_message.c
@@ -557,19 +557,19 @@
       if (mine == NULL)
         {
           if (IS_OSPF6_DEBUG_MESSAGE (oh->type, RECV))
-            zlog_info ("Add request (No database copy)", his->name);
+            zlog_info ("Add request (No database copy)");
           ospf6_lsdb_add (his, on->request_list);
         }
       else if (ospf6_lsa_compare (his, mine) < 0)
         {
           if (IS_OSPF6_DEBUG_MESSAGE (oh->type, RECV))
-            zlog_info ("Add request (Received MoreRecent)", his->name);
+            zlog_info ("Add request (Received MoreRecent)");
           ospf6_lsdb_add (his, on->request_list);
         }
       else
         {
           if (IS_OSPF6_DEBUG_MESSAGE (oh->type, RECV))
-            zlog_info ("Discard (Existing MoreRecent)", his->name);
+            zlog_info ("Discard (Existing MoreRecent)");
           ospf6_lsa_delete (his);
         }
     }
diff --git a/ospf6d/ospf6_route.c b/ospf6d/ospf6_route.c
index 1202a3a..dae9222 100644
--- a/ospf6d/ospf6_route.c
+++ b/ospf6d/ospf6_route.c
@@ -201,10 +201,25 @@
 _route_count_assert (struct ospf6_route_table *table)
 {
   struct ospf6_route *debug;
+  char buf[64];
   int num = 0;
   for (debug = ospf6_route_head (table); debug;
        debug = ospf6_route_next (debug))
     num++;
+
+  if (num == table->count)
+    return;
+
+  zlog_info ("PANIC !! table[%p]->count = %d, real = %d",
+             table, table->count, num);
+  for (debug = ospf6_route_head (table); debug;
+       debug = ospf6_route_next (debug))
+    {
+      prefix2str (&debug->prefix, buf, sizeof (buf));
+      zlog_info ("%p %p %s", debug->prev, debug->next, buf);
+    }
+  zlog_info ("DUMP END");
+
   assert (num == table->count);
 }
 #define ospf6_route_count_assert(t) (_route_count_assert (t))
diff --git a/ospf6d/ospf6_route.h b/ospf6d/ospf6_route.h
index 069502f..3d3e101 100644
--- a/ospf6d/ospf6_route.h
+++ b/ospf6d/ospf6_route.h
@@ -215,9 +215,9 @@
 #define ospf6_linkstate_prefix_id(x) \
   (*(u_int32_t *)(&(x)->u.prefix6.s6_addr[4]))
 
-#define ID_IN_PREFIX(x) \
-  (*(u_int32_t *)(&(x)->u.prefix6.s6_addr[0]))
 #define ADV_ROUTER_IN_PREFIX(x) \
+  (*(u_int32_t *)(&(x)->u.prefix6.s6_addr[0]))
+#define ID_IN_PREFIX(x) \
   (*(u_int32_t *)(&(x)->u.prefix6.s6_addr[4]))
 
 /* Function prototype */
diff --git a/ospf6d/ospf6_top.c b/ospf6d/ospf6_top.c
index 5710316..b031330 100644
--- a/ospf6d/ospf6_top.c
+++ b/ospf6d/ospf6_top.c
@@ -100,15 +100,17 @@
 void
 ospf6_top_brouter_hook_add (struct ospf6_route *route)
 {
-  ospf6_abr_originate_summary (route);
+  ospf6_abr_examin_brouter (ADV_ROUTER_IN_PREFIX (&route->prefix));
   ospf6_asbr_lsentry_add (route);
+  ospf6_abr_originate_summary (route);
 }
 
 void
 ospf6_top_brouter_hook_remove (struct ospf6_route *route)
 {
-  ospf6_abr_originate_summary (route);
+  ospf6_abr_examin_brouter (ADV_ROUTER_IN_PREFIX (&route->prefix));
   ospf6_asbr_lsentry_remove (route);
+  ospf6_abr_originate_summary (route);
 }
 
 struct ospf6 *
diff --git a/ospf6d/ospf6d.h b/ospf6d/ospf6d.h
index 1b68a0f..b08d07c 100644
--- a/ospf6d/ospf6d.h
+++ b/ospf6d/ospf6d.h
@@ -22,7 +22,7 @@
 #ifndef OSPF6D_H
 #define OSPF6D_H
 
-#define OSPF6_DAEMON_VERSION    "0.9.7j"
+#define OSPF6_DAEMON_VERSION    "0.9.7k"
 
 /* global variables */
 extern int errno;
