diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2016-11-05 23:31:13 +0100 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2016-11-05 23:37:31 +0100 |
commit | 88752e06441b212029fe8d9fcc3c605ddbc1586d (patch) | |
tree | 0935c1ffc3b413f5d6db54189b9d102a5008d306 /src/cookie.c | |
parent | 52846a7ca04b0e0f1541c0db71ead44a422a9fb4 (diff) |
c89: the static keyword is okay in c99, but not in c89
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'src/cookie.c')
-rw-r--r-- | src/cookie.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cookie.c b/src/cookie.c index e8cf55b..8d66457 100644 --- a/src/cookie.c +++ b/src/cookie.c @@ -34,7 +34,7 @@ void cookie_init(struct cookie *cookie) init_rwsem(&cookie->lock); } -static void compute_mac1(u8 mac1[static COOKIE_LEN], const void *message, size_t len, const u8 pubkey[static NOISE_PUBLIC_KEY_LEN], const u8 psk[static NOISE_SYMMETRIC_KEY_LEN]) +static void compute_mac1(u8 mac1[COOKIE_LEN], const void *message, size_t len, const u8 pubkey[NOISE_PUBLIC_KEY_LEN], const u8 psk[NOISE_SYMMETRIC_KEY_LEN]) { struct blake2s_state state; len = len - sizeof(struct message_macs) + offsetof(struct message_macs, mac1); @@ -48,7 +48,7 @@ static void compute_mac1(u8 mac1[static COOKIE_LEN], const void *message, size_t blake2s_final(&state, mac1, COOKIE_LEN); } -static void compute_mac2(u8 mac2[static COOKIE_LEN], const void *message, size_t len, const u8 cookie[static COOKIE_LEN]) +static void compute_mac2(u8 mac2[COOKIE_LEN], const void *message, size_t len, const u8 cookie[COOKIE_LEN]) { len = len - sizeof(struct message_macs) + offsetof(struct message_macs, mac2); blake2s(mac2, message, cookie, COOKIE_LEN, len, COOKIE_LEN); @@ -71,7 +71,7 @@ static inline void put_secret(struct cookie_checker *checker) up_read(&checker->secret_lock); } -static void make_cookie(u8 cookie[static COOKIE_LEN], struct sk_buff *skb, struct cookie_checker *checker) +static void make_cookie(u8 cookie[COOKIE_LEN], struct sk_buff *skb, struct cookie_checker *checker) { struct blake2s_state state; const u8 *secret; |