Whamcloud - gitweb
LU-4082 llite: Chk ret of ll_prep_md_op_data in ll_dir_filler
[fs/lustre-release.git] / lustre / llite / file.c
index e2eb565..8006ad2 100644 (file)
@@ -669,16 +669,18 @@ restart:
                  * (bug 3430) */
                 /* XXX (green): Should not we bail out on any error here, not
                  * just open error? */
-                rc = it_open_error(DISP_OPEN_OPEN, it);
-                if (rc)
-                        GOTO(out_och_free, rc);
+               rc = it_open_error(DISP_OPEN_OPEN, it);
+               if (rc != 0)
+                       GOTO(out_och_free, rc);
 
-                LASSERT(it_disposition(it, DISP_ENQ_OPEN_REF));
+               LASSERTF(it_disposition(it, DISP_ENQ_OPEN_REF),
+                        "inode %p: disposition %x, status %d\n", inode,
+                        it_disposition(it, ~0), it->d.lustre.it_status);
 
-                rc = ll_local_open(file, it, fd, *och_p);
-                if (rc)
-                        GOTO(out_och_free, rc);
-        }
+               rc = ll_local_open(file, it, fd, *och_p);
+               if (rc)
+                       GOTO(out_och_free, rc);
+       }
        mutex_unlock(&lli->lli_och_mutex);
         fd = NULL;
 
@@ -3813,7 +3815,7 @@ again:
        }
 
        op_data = ll_prep_md_op_data(NULL, inode, inode, NULL,
-                       0, 0, LUSTRE_OPC_ANY, NULL);
+                                    0, 0, LUSTRE_OPC_ANY, NULL);
        if (IS_ERR(op_data)) {
                mutex_unlock(&lli->lli_layout_mutex);
                RETURN(PTR_ERR(op_data));