From 80ce46224a1fd2896fb197236f2cd8e13e97723b Mon Sep 17 00:00:00 2001 From: phil <phil> Date: Mon, 1 Sep 2003 19:01:46 +0000 Subject: [PATCH] b=1090 r=braam backport from b_devel to HEAD this patch to avoid an assertion in an unlikely error case where the server is unable to even begin to process an intent request --- lustre/llite/namei.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/lustre/llite/namei.c b/lustre/llite/namei.c index b9223e832a..5260825e62 100644 --- a/lustre/llite/namei.c +++ b/lustre/llite/namei.c @@ -326,11 +326,13 @@ int ll_intent_lock(struct inode *parent, struct dentry **de, request = it->it_data; LASSERT(request != NULL); - /* non-zero it_disposition indicates that the server performed the - * intent on our behalf. */ - LASSERT(it_disposition(it, DISP_IT_EXECD)); + if (!it_disposition(it, DISP_IT_EXECD)) { + /* The server failed before it even started executing the + * intent, i.e. because it couldn't unpack the request. */ + LASSERT(it->it_status != 0); + GOTO(drop_req, rc = it->it_status); + } - mds_body = lustre_msg_buf(request->rq_repmsg, 1, sizeof(*mds_body)); LASSERT(mds_body != NULL); /* mdc_enqueue checked */ LASSERT_REPSWABBED(request, 1); /* mdc_enqueue swabbed */ -- GitLab