svn commit: r245950 - head/sys/fs/ext2fs
Pedro F. Giffuni
pfg at FreeBSD.org
Sat Jan 26 21:50:53 UTC 2013
Author: pfg
Date: Sat Jan 26 21:50:52 2013
New Revision: 245950
URL: http://svnweb.freebsd.org/changeset/base/245950
Log:
Cosmetical off-by-one
Technically, the case when all the blocks are released
is not a sanity check.
Move further the comment while here.
Suggested by: bde
MFC after: 3 days
Modified:
head/sys/fs/ext2fs/ext2_inode.c
Modified: head/sys/fs/ext2fs/ext2_inode.c
==============================================================================
--- head/sys/fs/ext2fs/ext2_inode.c Sat Jan 26 21:29:45 2013 (r245949)
+++ head/sys/fs/ext2fs/ext2_inode.c Sat Jan 26 21:50:52 2013 (r245950)
@@ -341,9 +341,9 @@ done:
* Put back the real size.
*/
oip->i_size = length;
- if (oip->i_blocks > blocksreleased)
+ if (oip->i_blocks >= blocksreleased)
oip->i_blocks -= blocksreleased;
- else /* sanity */
+ else /* sanity */
oip->i_blocks = 0;
oip->i_flag |= IN_CHANGE;
vnode_pager_setsize(ovp, length);
More information about the svn-src-head
mailing list