Whamcloud - gitweb
fix a typo which makes cross link() fail.
authorhuanghua <huanghua>
Thu, 2 Nov 2006 05:24:13 +0000 (05:24 +0000)
committerhuanghua <huanghua>
Thu, 2 Nov 2006 05:24:13 +0000 (05:24 +0000)
lustre/mdd/mdd_object.c

index b419783..e0490e3 100644 (file)
@@ -1038,13 +1038,13 @@ static int mdd_ref_add(const struct lu_env *env,
 
         mdd_write_lock(env, mdd_obj);
         rc = mdd_link_sanity_check(env, NULL, mdd_obj);
-        if (!rc)
+        if (rc == 0)
                 mdd_ref_add_internal(env, mdd_obj, handle);
         mdd_write_unlock(env, mdd_obj);
 
         mdd_trans_stop(env, mdd, 0, handle);
 
-        RETURN(0);
+        RETURN(rc);
 }
 
 /* do NOT or the MAY_*'s, you'll get the weakest */