summaryrefslogtreecommitdiffstats
path: root/src/crypto_linux.c
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2013-08-20 06:02:29 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2013-08-20 06:08:07 +0200
commitd9dc87d8409ddf8361b7fcb311ae97088ed1d984 (patch)
treec63be2cf2a7d978dd5b30b3a404d9442acefdff7 /src/crypto_linux.c
parent3fd947a2d13a3f110f7c558b1d294dddfd2d25e0 (diff)
downloadfastd-d9dc87d8409ddf8361b7fcb311ae97088ed1d984.tar
fastd-d9dc87d8409ddf8361b7fcb311ae97088ed1d984.zip
Fix lots of -Wextra warnings
Everything clang and GCC warn about, except GCC's missing-field-initializers which are just stupid as they don't allow {} syntax to zero a field.
Diffstat (limited to 'src/crypto_linux.c')
-rw-r--r--src/crypto_linux.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/crypto_linux.c b/src/crypto_linux.c
index 477547e..2cd7145 100644
--- a/src/crypto_linux.c
+++ b/src/crypto_linux.c
@@ -134,21 +134,21 @@ static bool aes128ctr_crypt(fastd_context_t *ctx, const fastd_crypto_aes128ctr_s
return true;
}
-static void aes128ctr_free_state(fastd_context_t *ctx, fastd_crypto_aes128ctr_state_t *cstate) {
+static void aes128ctr_free_state(fastd_context_t *ctx UNUSED, fastd_crypto_aes128ctr_state_t *cstate) {
if (cstate) {
close(cstate->fd);
free(cstate);
}
}
-static void aes128ctr_free(fastd_context_t *ctx, fastd_crypto_aes128ctr_context_t *cctx) {
+static void aes128ctr_free(fastd_context_t *ctx UNUSED, fastd_crypto_aes128ctr_context_t *cctx) {
if (cctx) {
close(cctx->fd);
free(cctx);
}
}
-fastd_crypto_aes128ctr_t fastd_crypto_aes128ctr_linux = {
+const fastd_crypto_aes128ctr_t fastd_crypto_aes128ctr_linux = {
.name = "linux",
.init = aes128ctr_init,
@@ -233,21 +233,21 @@ static bool ghash_hash(fastd_context_t *ctx, const fastd_crypto_ghash_state_t *c
return true;
}
-static void ghash_free_state(fastd_context_t *ctx, fastd_crypto_ghash_state_t *cstate) {
+static void ghash_free_state(fastd_context_t *ctx UNUSED, fastd_crypto_ghash_state_t *cstate) {
if (cstate) {
close(cstate->fd);
free(cstate);
}
}
-static void ghash_free(fastd_context_t *ctx, fastd_crypto_ghash_context_t *cctx) {
+static void ghash_free(fastd_context_t *ctx UNUSED, fastd_crypto_ghash_context_t *cctx) {
if (cctx) {
close(cctx->fd);
free(cctx);
}
}
-fastd_crypto_ghash_t fastd_crypto_ghash_linux = {
+const fastd_crypto_ghash_t fastd_crypto_ghash_linux = {
.name = "linux",
.init = ghash_init,