chiark / gitweb /
changelog: start 0.6.8
[secnet.git] / polypath.c
index a8b27599595cf8134b3d9e226bc34d8d04fb22af..adac598b3505784f2a3065ad17e49fcb3a15c06f 100644 (file)
@@ -7,7 +7,7 @@
  *
  * secnet is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version d of the License, or
+ * the Free Software Foundation; either version 3 of the License, or
  * (at your option) any later version.
  * 
  * secnet is distributed in the hope that it will be useful, but
@@ -27,6 +27,7 @@
 
 #include <adns.h>
 #include <ctype.h>
+#include <limits.h>
 
 #ifdef CONFIG_IPV6
 
@@ -352,7 +353,7 @@ static void polypath_record_ifaddr(struct polypath *st,
     struct interf_list *interfs;
     switch (want) {
     case '+': interfs=&st->interfs_general; max_interfs=st->max_interfs; break;
-    case '@':  interfs=&st->interfs_dedicated;  max_interfs=INT_MAX;
+    case '@': interfs=&st->interfs_dedicated; max_interfs=INT_MAX; break;
     default:   fatal("polypath: got bad want (%#x, %s)", want, ifname);
     }
 
@@ -503,9 +504,6 @@ static void polypath_sendmsg_interf(struct polypath *st,
        }
        if (!(errno==EAFNOSUPPORT || errno==ENETUNREACH))
            reasonable=True;
-       lg_perror(LG,M_DEBUG,errno,"%s [%s] xmit %"PRIu32" bytes to %s",
-                 interf->name,iaddr_to_string(&us->addr),
-                 buf->size,iaddr_to_string(&dest->ia));
     }
     if (!wanted)
        return;
@@ -516,7 +514,7 @@ static void polypath_sendmsg_interf(struct polypath *st,
                      "%s has no suitable address to transmit %s",
                      interf->name, af_name(af));
 
-    *allreasonable *= reasonable;
+    *allreasonable &= reasonable;
 }
 
 static bool_t polypath_sendmsg(void *commst, struct buffer_if *buf,