X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Flfsck%2Flfsck_namespace.c;h=1cb3963a5002c0c0161a0a926dd3cb650654a8b2;hp=4384bb8e2ccc19309c6a20780637e6dc79702ce2;hb=555d02f47401340182b47b3245a657b52fc3e68a;hpb=5801dad47e4727a44b6343a3f7f875d7992f29a3 diff --git a/lustre/lfsck/lfsck_namespace.c b/lustre/lfsck/lfsck_namespace.c index 4384bb8..1cb3963 100644 --- a/lustre/lfsck/lfsck_namespace.c +++ b/lustre/lfsck/lfsck_namespace.c @@ -2688,7 +2688,8 @@ again: * When the LFSCK runs again, if the dangling name is still * there, the LFSCK should move the orphan directory object * back to the normal namespace. */ - if (!lpf && !lu_fid_eq(pfid, &tfid) && once) { + if (!lpf && !fid_is_zero(pfid) && + !lu_fid_eq(pfid, &tfid) && once) { linkea_next_entry(ldata); continue; } @@ -2739,7 +2740,7 @@ again: * directory contains the specified child, but such * parent does not match the dotdot name entry, then * trust the linkEA. */ - if (!lu_fid_eq(pfid, pfid2)) { + if (!fid_is_zero(pfid) && !lu_fid_eq(pfid, pfid2)) { *type = LNIT_UNMATCHED_PAIRS; rc = lfsck_namespace_repair_unmatched_pairs(env, com, child, pfid2, cname);