Commit c0d4f714 authored by yidong0635's avatar yidong0635 Committed by Changpeng Liu
Browse files

crypto: Fix scanbuild issue on Fedora30.



Issue reports:
vbdev_crypto.c:695:12: warning: The left operand of '+' is a garbage value
                iv_ptr = rte_crypto_op_ctod_offset(crypto_ops[crypto_index], uint8_t *,

Change-Id: I1a4f89111e94a13d8daf38070aa69306783a83c5
Signed-off-by: default avataryidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/462576


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarDarek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
parent 2ab92703
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -631,6 +631,9 @@ _crypto_operation(struct spdk_bdev_io *bdev_io, enum rte_crypto_cipher_operation
	}

	/* Allocate crypto operations. */
#ifdef DEBUG
	memset(crypto_ops, 0, sizeof(crypto_ops));
#endif
	allocated = rte_crypto_op_bulk_alloc(g_crypto_op_mp,
					     RTE_CRYPTO_OP_TYPE_SYMMETRIC,
					     crypto_ops, cryop_cnt);