summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaslo Hunhold <dev@frign.de>2017-08-02 21:46:54 +0200
committerLaslo Hunhold <dev@frign.de>2017-08-02 21:46:54 +0200
commit9e0a561d7453d4f92051496314e4edcc06a97ae5 (patch)
tree8305a16f3d57346e070320d3e838be21473c29bc
parentf0f85f1a0cfcd6d501aee848238913a4fd1e0606 (diff)
Combine all license matters in LICENSE
We use some OpenBSD code in util.c (namely by Ted Unangst, Todd C. Miller and Otto Moerbeek), which is licensed under the ISC license. To make it clearer and make it easier to see what farbfeld really is licensed under, we include these authors in the LICENSE file and remove the explicit headers from util.c. While at it, we also remove superfluous includes and shove them to the top.
-rw-r--r--LICENSE15
-rw-r--r--util.c46
2 files changed, 12 insertions, 49 deletions
diff --git a/LICENSE b/LICENSE
index 30c84f5..1bf035c 100644
--- a/LICENSE
+++ b/LICENSE
@@ -2,6 +2,15 @@ ISC-License
(c) 2014-2017 Laslo Hunhold <dev@frign.de>
+(c) 2004 Ted Unangst <tedu@openbsd.org>
+(c) 2004 Todd C. Miller <Todd.Miller@courtesan.com>
+(c) 2008 Otto Moerbeek <otto@drijf.net>
+(c) 2014-2015 Dimitris Papastamos <sin@2f30.org>
+(c) 2014-2016 Hiltjo Posthuma <hiltjo@codemadness.org>
+(c) 2015 Willy Goiffon <willy@mailoo.org>
+(c) 2016 Alexander Krotov <ilabdsf@yandex.ru>
+(c) 2017 Mattias Andrée <maandree@kth.se>
+
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
@@ -14,8 +23,4 @@ WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-(c) 2014-2015 Dimitris Papastamos <sin@2f30.org>
-(c) 2014-2016 Hiltjo Posthuma <hiltjo@codemadness.org>
-(c) 2015 Willy Goiffon <willy@mailoo.org>
-(c) 2016 Alexander Krotov <ilabdsf@yandex.ru>
-(c) 2017 Mattias Andrée <maandree@kth.se>
+
diff --git a/util.c b/util.c
index ba139b4..f9cf33e 100644
--- a/util.c
+++ b/util.c
@@ -2,10 +2,12 @@
#include <arpa/inet.h>
#include <errno.h>
+#include <limits.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <sys/types.h>
#include "util.h"
@@ -134,27 +136,6 @@ estrtonum(const char *numstr, long long minval, long long maxval)
}
/*
- * Copyright (c) 2008 Otto Moerbeek <otto@drijf.net>
- *
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#include <sys/types.h>
-#include <errno.h>
-#include <stdint.h>
-#include <stdlib.h>
-
-/*
* This is sqrt(SIZE_MAX+1), as s1*s2 <= SIZE_MAX
* if both s1 < MUL_NO_OVERFLOW and s2 < MUL_NO_OVERFLOW
*/
@@ -171,29 +152,6 @@ reallocarray(void *optr, size_t nmemb, size_t size)
return realloc(optr, size * nmemb);
}
-/* $OpenBSD: strtonum.c,v 1.7 2013/04/17 18:40:58 tedu Exp $ */
-
-/*
- * Copyright (c) 2004 Ted Unangst and Todd Miller
- * All rights reserved.
- *
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#include <errno.h>
-#include <limits.h>
-#include <stdlib.h>
-
#define INVALID 1
#define TOOSMALL 2
#define TOOLARGE 3