The first argument passed to qsort() in fsrfs() is an array of "struct
xfs_bulkstat". Hence the two arguments to the cmp() function must be
interpreted as being of type "struct xfs_bulkstat *" as against "struct
xfs_bstat *" that is being used to currently typecast them.
Signed-off-by: Chandan Babu R <chandanrlinux@gmail.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
int
cmp(const void *s1, const void *s2)
{
- return( ((struct xfs_bstat *)s2)->bs_extents -
- ((struct xfs_bstat *)s1)->bs_extents);
-
+ return( ((struct xfs_bulkstat *)s2)->bs_extents -
+ ((struct xfs_bulkstat *)s1)->bs_extents);
}
/*