]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/ext2/ioctl.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
[linux-2.6-omap-h63xx.git] / fs / ext2 / ioctl.c
index c2324d5fe4ac149a5672bad13134d4775c815100..320b2cb3d4d22eddf610d7a27d043eeef0437d5e 100644 (file)
@@ -47,6 +47,11 @@ int ext2_ioctl (struct inode * inode, struct file * filp, unsigned int cmd,
                        flags &= ~EXT2_DIRSYNC_FL;
 
                mutex_lock(&inode->i_mutex);
+               /* Is it quota file? Do not allow user to mess with it */
+               if (IS_NOQUOTA(inode)) {
+                       mutex_unlock(&inode->i_mutex);
+                       return -EPERM;
+               }
                oldflags = ei->i_flags;
 
                /*