X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Fmeta.c;h=f6a9ba18e685b1273ce6279338966b5df14b16bf;hb=bcac314fe2d758e85335d499dbb4300bfa8a599e;hp=7a8baac4a5e0ab9d61566950a976157288bb28e2;hpb=0c443c53163e97ebe9897984a4a2a5c5c620b4cc;p=tinc diff --git a/src/meta.c b/src/meta.c index 7a8baac4..f6a9ba18 100644 --- a/src/meta.c +++ b/src/meta.c @@ -78,7 +78,7 @@ bool send_meta(connection_t *c, const void *buffer, size_t length) { size_t outlen = length; - if(!cipher_encrypt(c->outcipher, buffer, length, buffer_prepare(&c->outbuf, length), &outlen, false) || outlen != length) { + if(!cipher_encrypt(&c->outcipher, buffer, length, buffer_prepare(&c->outbuf, length), &outlen, false) || outlen != length) { logger(DEBUG_ALWAYS, LOG_ERR, "Error while encrypting metadata to %s (%s)", c->name, c->hostname); return false; @@ -258,7 +258,7 @@ bool receive_meta(connection_t *c) { size_t outlen = inlen; - if(!cipher_decrypt(c->incipher, bufp, inlen, buffer_prepare(&c->inbuf, inlen), &outlen, false) || (size_t)inlen != outlen) { + if(!cipher_decrypt(&c->incipher, bufp, inlen, buffer_prepare(&c->inbuf, inlen), &outlen, false) || (size_t)inlen != outlen) { logger(DEBUG_ALWAYS, LOG_ERR, "Error while decrypting metadata from %s (%s)", c->name, c->hostname); return false;