
4 Sep
2024
4 Sep
'24
5:04 p.m.
The null pointer check is added. Signed-off-by: Qi Tao <taoqi10@huawei.com> --- drv/isa_ce_sm4.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drv/isa_ce_sm4.c b/drv/isa_ce_sm4.c index e9378930..3420f992 100644 --- a/drv/isa_ce_sm4.c +++ b/drv/isa_ce_sm4.c @@ -37,7 +37,7 @@ static int isa_ce_init(struct wd_alg_driver *drv, void *conf) struct sm4_ce_drv_ctx *sctx = drv->priv; /* Fallback init is NULL */ - if (!drv || !conf) + if (!drv->priv || !conf) return 0; config->epoll_en = 0; -- 2.33.0