Whamcloud - gitweb
b=22634 hold "mds_qonoff_sem" when call "lustre_read_quota()", and check parameter...
[fs/lustre-release.git] / lustre / lvfs / lustre_quota_fmt.c
index d169bb7..26944fc 100644 (file)
@@ -103,15 +103,8 @@ int check_quota_file(struct file *f, struct inode *inode, int type,
         static const uint quota_magics[] = LUSTRE_INITQMAGICS;
         const uint *quota_versions = lustre_initqversions[version];
 
-        if (!f && !inode) {
-                CERROR("check_quota_file failed!\n");
-                libcfs_debug_dumpstack(NULL);
-                return -EINVAL;
-        }
-
         size = lustre_read_quota(f, inode, type, (char *)&dqhead,
                                  sizeof(struct lustre_disk_dqheader), 0);
-
         if (size != sizeof(struct lustre_disk_dqheader))
                 return -EINVAL;
         if (le32_to_cpu(dqhead.dqh_magic) != quota_magics[type] ||