patch-2.1.102 linux/fs/ext2/ialloc.c
Next file: linux/fs/filesystems.c
Previous file: linux/fs/ext2/balloc.c
Back to the patch index
Back to the overall index
- Lines: 24
- Date:
Fri May 8 22:55:06 1998
- Orig file:
v2.1.101/linux/fs/ext2/ialloc.c
- Orig date:
Fri May 8 23:14:53 1998
diff -u --recursive --new-file v2.1.101/linux/fs/ext2/ialloc.c linux/fs/ext2/ialloc.c
@@ -405,7 +405,7 @@
return NULL;
}
bitmap_nr = load_inode_bitmap (sb, i);
- if (bitmap_nr < 0) {
+ if (bitmap_nr < 0) {
unlock_super (sb);
iput(inode);
*err = -EIO;
@@ -493,7 +493,13 @@
inc_inode_version (inode, gdp, mode);
unlock_super (sb);
- DQUOT_ALLOC_INODE(sb, inode);
+ if(DQUOT_ALLOC_INODE(sb, inode)) {
+ sb->dq_op->drop(inode);
+ inode->i_nlink = 0;
+ iput(inode);
+ *err = -EDQUOT;
+ return NULL;
+ }
ext2_debug ("allocating inode %lu\n", inode->i_ino);
*err = 0;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov