aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack O'Connor <[email protected]>2021-02-15 14:23:49 -0500
committerJack O'Connor <[email protected]>2021-02-15 14:24:37 -0500
commit8969cdd2f8cdd033fed9acc80a83e9be1998f3d6 (patch)
treee25c2cc204f89e8a58e32b80e2568e381ed17257
parent8c350836b81477a5ea49f14e5ca636f1eb1102f5 (diff)
clang-format a few files
Some of the SIMD code is still unformatted, so for now I'm only touching the files that just have a couple small changes.
-rw-r--r--c/blake3.c4
-rw-r--r--c/blake3.h4
-rw-r--r--c/main.c4
3 files changed, 5 insertions, 7 deletions
diff --git a/c/blake3.c b/c/blake3.c
index 7abf532..9998f75 100644
--- a/c/blake3.c
+++ b/c/blake3.c
@@ -5,9 +5,7 @@
#include "blake3.h"
#include "blake3_impl.h"
-const char * blake3_version(void) {
- return BLAKE3_VERSION_STRING;
-}
+const char *blake3_version(void) { return BLAKE3_VERSION_STRING; }
INLINE void chunk_state_init(blake3_chunk_state *self, const uint32_t key[8],
uint8_t flags) {
diff --git a/c/blake3.h b/c/blake3.h
index 57ebd5a..94ebc5f 100644
--- a/c/blake3.h
+++ b/c/blake3.h
@@ -39,12 +39,12 @@ typedef struct {
uint8_t cv_stack[(BLAKE3_MAX_DEPTH + 1) * BLAKE3_OUT_LEN];
} blake3_hasher;
-const char * blake3_version(void);
+const char *blake3_version(void);
void blake3_hasher_init(blake3_hasher *self);
void blake3_hasher_init_keyed(blake3_hasher *self,
const uint8_t key[BLAKE3_KEY_LEN]);
void blake3_hasher_init_derive_key(blake3_hasher *self, const char *context);
-void blake3_hasher_init_derive_key_raw(blake3_hasher *self, const void *context,
+void blake3_hasher_init_derive_key_raw(blake3_hasher *self, const void *context,
size_t context_len);
void blake3_hasher_update(blake3_hasher *self, const void *input,
size_t input_len);
diff --git a/c/main.c b/c/main.c
index 9b8a436..7827b1c 100644
--- a/c/main.c
+++ b/c/main.c
@@ -107,10 +107,10 @@ int main(int argc, char **argv) {
argv += 2;
}
- /*
+ /*
* We're going to hash the input multiple times, so we need to buffer it all.
* This is just for test cases, so go ahead and assume that the input is less
- * than 1 MiB.
+ * than 1 MiB.
*/
size_t buf_capacity = 1 << 20;
uint8_t *buf = malloc(buf_capacity);