if the object doesn't exist during declaration.
Signed-off-by: Alex Zhuravlev <bzzz@whamcloud.com>
Change-Id: I7d42cad0c04e7941a2f7950fdddaf7c473998b12
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/52496
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
ENTRY;
LASSERT(th != NULL);
- LASSERT(dt_object_exists(dt));
+ if (unlikely(obj->oo_dn == NULL))
+ RETURN(-ENOENT);
oh = container_of(th, struct osd_thandle, ot_super);
LASSERT(oh->ot_tx != NULL);