diff options
author | Marco Varlese <marco.varlese@suse.com> | 2018-02-12 09:08:21 +0100 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2018-02-12 13:05:36 +0000 |
commit | 18b631560b17d5fd143c87d77f86a371cb93e6d8 (patch) | |
tree | 06a0305bb92fb9e9646739d4dcbe98cda879ab4c /src/vnet/sctp/sctp_output.c | |
parent | ffd78d1ef8fe80d1b756a71d42d5eadda60ae996 (diff) |
SCTP: fix build errors on ubuntu bionic
Change-Id: I070771794be92fd9a6e800ca0022e52d592cd1a4
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
Diffstat (limited to 'src/vnet/sctp/sctp_output.c')
-rw-r--r-- | src/vnet/sctp/sctp_output.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/vnet/sctp/sctp_output.c b/src/vnet/sctp/sctp_output.c index 276d7e70213..7657d0cd1e9 100644 --- a/src/vnet/sctp/sctp_output.c +++ b/src/vnet/sctp/sctp_output.c @@ -503,13 +503,12 @@ sctp_compute_mac (sctp_connection_t * sctp_conn, HMAC_CTX *ctx; #else HMAC_CTX ctx; - const EVP_MD *md = EVP_sha1 (); #endif unsigned int len = 0; - + const EVP_MD *md = EVP_sha1 (); #if OPENSSL_VERSION_NUMBER >= 0x10100000L ctx = HMAC_CTX_new (); - HMAC_Init_ex (&ctx, &state_cookie->creation_time, + HMAC_Init_ex (ctx, &state_cookie->creation_time, sizeof (state_cookie->creation_time), md, NULL); HMAC_Update (ctx, (const unsigned char *) &sctp_conn, sizeof (sctp_conn)); HMAC_Final (ctx, state_cookie->mac, &len); @@ -517,7 +516,6 @@ sctp_compute_mac (sctp_connection_t * sctp_conn, HMAC_CTX_init (&ctx); HMAC_Init_ex (&ctx, &state_cookie->creation_time, sizeof (state_cookie->creation_time), md, NULL); - HMAC_Update (&ctx, (const unsigned char *) &sctp_conn, sizeof (sctp_conn)); HMAC_Final (&ctx, state_cookie->mac, &len); HMAC_CTX_cleanup (&ctx); |