diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2016-07-20 10:37:13 +1000 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2016-07-20 10:37:13 +1000 |
commit | fbc21f33cda0a8e13ebd71fe2e23a21d4b79afbb (patch) | |
tree | 10c37d3ce264a198fc9f42449f2ce49c5280db92 /fs/xfs/xfs_error.h | |
parent | 7f1b62457b58f9bb586a1b2ff7fe271b56196bd2 (diff) |
xfs: don't allow negative error tags
Errors go from zero which means no error to XFS_ERRTAG_MAX (22). My
static checker complains that xfs_errortag_add() puts an upper bound on
this but not a lower bound. Let's fix it by making it unsigned.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
Diffstat (limited to 'fs/xfs/xfs_error.h')
-rw-r--r-- | fs/xfs/xfs_error.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/xfs_error.h b/fs/xfs/xfs_error.h index 4ed3042a0f16..2e4f67f68856 100644 --- a/fs/xfs/xfs_error.h +++ b/fs/xfs/xfs_error.h @@ -128,7 +128,7 @@ extern int xfs_error_test(int, int *, char *, int, char *, unsigned long); xfs_error_test((tag), (mp)->m_fixedfsid, "expr", __LINE__, __FILE__, \ (rf)))) -extern int xfs_errortag_add(int error_tag, struct xfs_mount *mp); +extern int xfs_errortag_add(unsigned int error_tag, struct xfs_mount *mp); extern int xfs_errortag_clearall(struct xfs_mount *mp, int loud); #else #define XFS_TEST_ERROR(expr, mp, tag, rf) (expr) |