]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: fix compiler warnings
authorDarrick J. Wong <darrick.wong@oracle.com>
Wed, 18 Oct 2017 18:39:01 +0000 (13:39 -0500)
committerEric Sandeen <sandeen@redhat.com>
Wed, 18 Oct 2017 18:39:01 +0000 (13:39 -0500)
Source kernel commit: 7bf7a193a90cadccaad21c5970435c665c40fe27

Fix up all the compiler warnings that have crept in.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_inode_fork.c

index c8778bec3ebd3d789f46bd696bf21f25dbf736ec..0c695cb5b3513bf28ee39f0f5b452eb9a5c5ab94 100644 (file)
@@ -1497,14 +1497,11 @@ xfs_iext_realloc_indirect(
        int             new_size)       /* new indirection array size */
 {
 #ifdef DEBUG
-       int             nlists;         /* number of irec's (ex lists) */
-       int             size;           /* current indirection array size */
-
        ASSERT(ifp->if_flags & XFS_IFEXTIREC);
-       nlists = ifp->if_real_bytes / XFS_IEXT_BUFSZ;
-       size = nlists * sizeof(xfs_ext_irec_t);
        ASSERT(ifp->if_real_bytes);
-       ASSERT((new_size >= 0) && (new_size != size));
+       ASSERT((new_size >= 0) &&
+              (new_size != ((ifp->if_real_bytes / XFS_IEXT_BUFSZ) *
+                            sizeof(xfs_ext_irec_t))));
 #endif
        if (new_size == 0) {
                xfs_iext_destroy(ifp);