summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlex Xu (Hello71) <alex_y_xu@yahoo.ca>2018-08-15 13:18:17 -0400
committerAlex Xu (Hello71) <alex_y_xu@yahoo.ca>2018-08-15 13:18:17 -0400
commit39e07e62f471cbf40503cdc1926da6fef0cc0a3e (patch)
treec45259dd22402921f80067864b34d3ab9b258d58 /src
parent8d90ffb43214c390f6921e058a3cb164075ff1c5 (diff)
downloadrandom-seed-39e07e62f471cbf40503cdc1926da6fef0cc0a3e.tar.xz
random-seed-39e07e62f471cbf40503cdc1926da6fef0cc0a3e.zip
Source cleanups.
Diffstat (limited to 'src')
-rw-r--r--src/musl-libgen-c.h3
-rw-r--r--src/random-seed.c16
-rw-r--r--src/sha2.c3
-rw-r--r--src/sha2.h3
-rw-r--r--src/util.c2
-rw-r--r--src/util.h6
6 files changed, 14 insertions, 19 deletions
diff --git a/src/musl-libgen-c.h b/src/musl-libgen-c.h
index 99c90ee..d947197 100644
--- a/src/musl-libgen-c.h
+++ b/src/musl-libgen-c.h
@@ -1,4 +1,5 @@
-/*
+/* SPDX-License-Identifier: MIT
+ *
* Copied from musl.
*
* Copyright © 2005-2014 Rich Felker, et al.
diff --git a/src/random-seed.c b/src/random-seed.c
index 0b7c5c4..b8e8ad7 100644
--- a/src/random-seed.c
+++ b/src/random-seed.c
@@ -1,17 +1,4 @@
-/* Copyright 2018 Alex Xu (aka Hello71, alxu)
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
+// SPDX-License-Identifier: BSD-3-Clause
#include <assert.h>
#include <errno.h>
@@ -30,6 +17,7 @@
#include <sys/syscall.h>
#include <unistd.h>
+#include "config.h"
#include "musl-libgen-c.h"
#include "util.h"
diff --git a/src/sha2.c b/src/sha2.c
index 4c2b615..d949537 100644
--- a/src/sha2.c
+++ b/src/sha2.c
@@ -1,4 +1,5 @@
-/*
+/* SPDX-License-Identifier: BSD-3-Clause
+ *
* FIPS 180-2 SHA-224/256/384/512 implementation
* Last update: 02/02/2007
* Issue date: 04/30/2005
diff --git a/src/sha2.h b/src/sha2.h
index bd968ba..e55b74f 100644
--- a/src/sha2.h
+++ b/src/sha2.h
@@ -1,4 +1,5 @@
-/*
+/* SPDX-License-Identifier: BSD-3-Clause
+ *
* FIPS 180-2 SHA-224/256/384/512 implementation
* Last update: 02/02/2007
* Issue date: 04/30/2005
diff --git a/src/util.c b/src/util.c
index a5eb220..908e3a2 100644
--- a/src/util.c
+++ b/src/util.c
@@ -1,3 +1,5 @@
+// SPDX-License-Identifier: BSD-3-Clause
+
#include <assert.h>
#include <limits.h>
#include <stddef.h>
diff --git a/src/util.h b/src/util.h
index 9cd2bd4..8759cd0 100644
--- a/src/util.h
+++ b/src/util.h
@@ -1,5 +1,7 @@
-#ifndef UTIL_H
-#define UTIL_H
+// SPDX-License-Identifier: BSD-3-Clause
+
+#ifndef RANDOM_SEED_UTIL_H
+#define RANDOM_SEED_UTIL_H
#include <errno.h>
#include <stdbool.h>