summaryrefslogtreecommitdiff
path: root/sys/crypto
diff options
context:
space:
mode:
authorChristiano F. Haesbaert <haesbaert@cvs.openbsd.org>2012-10-04 13:17:13 +0000
committerChristiano F. Haesbaert <haesbaert@cvs.openbsd.org>2012-10-04 13:17:13 +0000
commitf1b4b7da940d5f2b80e86f4f4e0cc1d6b21fea3e (patch)
tree1906693c2fef5697d3f844eca3271997592d559a /sys/crypto
parentf2b45cb94b4f6178957bc54fa744b2379461df94 (diff)
Clean up uninitialized warnings from cryptosoft and aesni.
Part of the work to remove -Wno-uninitialized. ok mikeb@
Diffstat (limited to 'sys/crypto')
-rw-r--r--sys/crypto/cryptosoft.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/crypto/cryptosoft.c b/sys/crypto/cryptosoft.c
index 962b09e15f3..204b7193c30 100644
--- a/sys/crypto/cryptosoft.c
+++ b/sys/crypto/cryptosoft.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cryptosoft.c,v 1.64 2012/06/29 14:48:04 mikeb Exp $ */
+/* $OpenBSD: cryptosoft.c,v 1.65 2012/10/04 13:17:12 haesbaert Exp $ */
/*
* The author of this code is Angelos D. Keromytis (angelos@cis.upenn.edu)
@@ -501,7 +501,7 @@ swcr_combined(struct cryptop *crp)
u_char iv[EALG_MAX_BLOCK_LEN];
union authctx ctx;
struct cryptodesc *crd, *crda = NULL, *crde = NULL;
- struct swcr_data *sw, *swa, *swe;
+ struct swcr_data *sw, *swa, *swe = NULL;
struct auth_hash *axf = NULL;
struct enc_xform *exf = NULL;
struct mbuf *m = NULL;
@@ -510,6 +510,8 @@ swcr_combined(struct cryptop *crp)
uint32_t *blkp;
int aadlen, blksz, i, ivlen, outtype, left, len;
+ ivlen = blksz = 0;
+
for (crd = crp->crp_desc; crd; crd = crd->crd_next) {
for (sw = swcr_sessions[crp->crp_sid & 0xffffffff];
sw && sw->sw_alg != crd->crd_alg;