From ca50154286e58971ef7165ee7018ebd6a0540281 Mon Sep 17 00:00:00 2001 From: pjd Date: Thu, 18 May 2006 06:28:39 +0000 Subject: Silent Coverity Prevent report by asserting that cap != NULL. Coverity ID: 1414 --- sys/opencrypto/crypto.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'sys/opencrypto') diff --git a/sys/opencrypto/crypto.c b/sys/opencrypto/crypto.c index e1c7e99..74f147e 100644 --- a/sys/opencrypto/crypto.c +++ b/sys/opencrypto/crypto.c @@ -1071,8 +1071,8 @@ crypto_proc(void) * Driver cannot disappeared when there is an active * session. */ - KASSERT(cap != NULL, ("%s: Driver disappeared.", - __func__)); + KASSERT(cap != NULL, ("%s:%u Driver disappeared.", + __func__, __LINE__)); if (cap == NULL || cap->cc_process == NULL) { /* Op needs to be migrated, process it. */ if (submit == NULL) @@ -1105,6 +1105,8 @@ crypto_proc(void) CRYPTO_Q_UNLOCK(); hid = CRYPTO_SESID2HID(submit->crp_sid); cap = crypto_checkdriver(hid); + KASSERT(cap != NULL, ("%s:%u Driver disappeared.", + __func__, __LINE__)); result = crypto_invoke(cap, submit, hint); CRYPTO_Q_LOCK(); if (result == ERESTART) { -- cgit v1.1