Do not advertise the default route with wrong metric of 0. Set it to 1
authorclaudio <claudio@openbsd.org>
Tue, 5 Aug 2008 06:51:12 +0000 (06:51 +0000)
committerclaudio <claudio@openbsd.org>
Tue, 5 Aug 2008 06:51:12 +0000 (06:51 +0000)
by default. Reminded to commit this brad@, OK deraadt@

usr.sbin/ripd/ripd.c

index cdba3cc..05574b6 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: ripd.c,v 1.9 2008/05/12 19:15:02 pyr Exp $ */
+/*     $OpenBSD: ripd.c,v 1.10 2008/08/05 06:51:12 claudio Exp $ */
 
 /*
  * Copyright (c) 2006 Michele Marchetto <mydecay@openbeer.it>
@@ -531,6 +531,7 @@ ripd_redistribute_default(int type)
                return;
 
        bzero(&kr, sizeof(kr));
+       kr.metric = 1;  /* default metric */
        main_imsg_compose_rde(type, 0, &kr, sizeof(struct kroute));
 }