Whamcloud - gitweb
LU-3201 lmv: check result of lmv_find_target()
[fs/lustre-release.git] / lustre / lmv / lmv_internal.h
index bef090c..04c092e 100644 (file)
@@ -123,7 +123,8 @@ lmv_get_target(struct lmv_obd *lmv, mdsno_t mds)
                if (lmv->tgts[i]->ltd_idx == mds)
                        return lmv->tgts[i];
        }
-       return NULL;
+
+       return ERR_PTR(-ENODEV);
 }
 
 static inline struct lmv_tgt_desc *