Commit f85065e5 authored by Dmitry Eremin's avatar Dmitry Eremin Committed by Greg Kroah-Hartman

staging/lustre/ldlm: fix NULL pointer dereference

Pointer '*exp' returned from call to function 'class_conn2export'
at line 523 may be NULL and may be dereferenced at line 543.
Signed-off-by: default avatarDmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/9323
ntel-bug-id: https://jira.hpdd.intel.com/browse/LU-4629Reviewed-by: default avatarJohn L. Hammond <john.hammond@intel.com>
Reviewed-by: default avatarJames Simmons <uja.ornl@gmail.com>
Signed-off-by: default avatarOleg Drokin <oleg.drokin@intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a700f975
...@@ -514,7 +514,7 @@ int client_connect_import(const struct lu_env *env, ...@@ -514,7 +514,7 @@ int client_connect_import(const struct lu_env *env,
LASSERT (imp->imp_state == LUSTRE_IMP_DISCON); LASSERT (imp->imp_state == LUSTRE_IMP_DISCON);
GOTO(out_ldlm, rc); GOTO(out_ldlm, rc);
} }
LASSERT((*exp)->exp_connection); LASSERT(*exp != NULL && (*exp)->exp_connection);
if (data) { if (data) {
LASSERTF((ocd->ocd_connect_flags & data->ocd_connect_flags) == LASSERTF((ocd->ocd_connect_flags & data->ocd_connect_flags) ==
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment