GFS2: Fix typo in stuffed file data copy handling
authorAbhijith Das <adas@redhat.com>
Fri, 30 Jul 2010 15:34:52 +0000 (11:34 -0400)
committerSteven Whitehouse <swhiteho@redhat.com>
Fri, 30 Jul 2010 15:34:06 +0000 (16:34 +0100)
trunc_start() in bmap.c incorrectly uses sizeof(struct gfs2_inode) instead of
sizeof(struct gfs2_dinode).

Signed-off-by: Abhi Das <adas@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/bmap.c

index 744c29e2dcf46a5859b492ae389cb7ba77745821..6f482809d1a35b4787e9cb62357958d532aeaa30 100644 (file)
@@ -1040,7 +1040,7 @@ static int trunc_start(struct gfs2_inode *ip, u64 size)
                goto out;
 
        if (gfs2_is_stuffed(ip)) {
-               u64 dsize = size + sizeof(struct gfs2_inode);
+               u64 dsize = size + sizeof(struct gfs2_dinode);
                ip->i_disksize = size;
                ip->i_inode.i_mtime = ip->i_inode.i_ctime = CURRENT_TIME;
                gfs2_trans_add_bh(ip->i_gl, dibh, 1);