chiark / gitweb /
When printing messages about dropping IPv6, do not print anything about ihl.
[secnet.git] / secnet.c
index 30db8e1878a66065cf97ba6e7d1c0aa0d0d379f2..8fb8affe43f80d6cebab337e504524b7f3907756 100644 (file)
--- a/secnet.c
+++ b/secnet.c
@@ -1,3 +1,22 @@
+/*
+ * This file is part of secnet.
+ * See README for full list of copyright holders.
+ *
+ * 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
+ * (at your option) any later version.
+ * 
+ * secnet is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * version 3 along with secnet; if not, see
+ * https://www.gnu.org/licenses/gpl.html.
+ */
+
 #include "secnet.h"
 #include <stdio.h>
 #include <assert.h>
@@ -235,7 +254,7 @@ struct poll_interest *register_for_poll(void *st, beforepoll_fn *before,
 {
     struct poll_interest *i;
 
-    i=safe_malloc(sizeof(*i),"register_for_poll");
+    NEW(i);
     i->before=before;
     i->after=after;
     i->state=st;
@@ -331,7 +350,7 @@ static void run(void)
        if (shortfall) {
            allocdfds *= 2;
            allocdfds += shortfall;
-           fds=safe_realloc_ary(fds,sizeof(*fds),allocdfds, "run");
+           REALLOC_ARY(fds,allocdfds);
        }
        shortfall=0;
        idx=0;