diff options
author | 2015-02-07 05:45:06 +0000 | |
---|---|---|
committer | 2015-02-07 05:45:06 +0000 | |
commit | 4682b2eb22fbedba91c3be00ed9fae8a08f6a51f (patch) | |
tree | 974488d2e94e9e8075b81118c2198c0101b7b765 | |
parent | userland gets static on functions only used within a file. (diff) | |
download | wireguard-openbsd-4682b2eb22fbedba91c3be00ed9fae8a08f6a51f.tar.xz wireguard-openbsd-4682b2eb22fbedba91c3be00ed9fae8a08f6a51f.zip |
keep this in sync a bit with userland by putting static on functions
that are only used in this file.
tedu argues if something sucks we would fault before we can get to
these, and they dont do anything except maths. these symbols dont
need to be visible to ddb.
originally from Fritjof Bornebusch
suggested by and ok tedu@
-rw-r--r-- | sys/crypto/siphash.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/crypto/siphash.c b/sys/crypto/siphash.c index b4ea277827e..0af97a0662b 100644 --- a/sys/crypto/siphash.c +++ b/sys/crypto/siphash.c @@ -1,4 +1,4 @@ -/* $OpenBSD: siphash.c,v 1.1 2014/11/04 03:01:14 dlg Exp $ */ +/* $OpenBSD: siphash.c,v 1.2 2015/02/07 05:45:06 dlg Exp $ */ /*- * Copyright (c) 2013 Andre Oppermann <andre@FreeBSD.org> @@ -48,8 +48,8 @@ #include <crypto/siphash.h> -void SipHash_CRounds(SIPHASH_CTX *, int); -void SipHash_Rounds(SIPHASH_CTX *, int); +static void SipHash_CRounds(SIPHASH_CTX *, int); +static void SipHash_Rounds(SIPHASH_CTX *, int); void SipHash_Init(SIPHASH_CTX *ctx, const SIPHASH_KEY *key) @@ -147,7 +147,7 @@ SipHash(const SIPHASH_KEY *key, int rc, int rf, const void *src, size_t len) #define SIP_ROTL(x, b) ((x) << (b)) | ( (x) >> (64 - (b))) -void +static void SipHash_Rounds(SIPHASH_CTX *ctx, int rounds) { while (rounds--) { @@ -171,7 +171,7 @@ SipHash_Rounds(SIPHASH_CTX *ctx, int rounds) } } -void +static void SipHash_CRounds(SIPHASH_CTX *ctx, int rounds) { u_int64_t m = lemtoh64((u_int64_t *)ctx->buf); |